INFORMATICA UMANISTICA B DA DATI NON STRUTTURATI A


0b348da00f82b79de9243b32b810719d.ppt
- Количество слайдов: 40
INFORMATICA UMANISTICA B DA DATI NON STRUTTURATI A DATI STRUTTURATI: LINGUAGGI DI MARCATURA XML TEI
AGGIUNGERE STRUTTURA A DATI NON STRUTTURATI USANDO LINGUAGGI DI MARCATURA l In questa lezione e la prossima discuteremo di come sia possibile usare LINGUAGGI DI MARCATURA come XML per rendere ‘parzialmente strutturati’ dati testuali l l Oggi: aggiungere struttura a testi Prossima lezione: aggiungere informazione semantica
LINGUAGGI DI MARCATURA l l Permettono di aggiungere informazione (‘annotare’) un testo Due tipi di informazione: l Aspetto (formattazione, disposizione degli elementi sulla pagina) l l HTML Struttura logica l XML
TIPI DI LINGUAGGI DI MARCATURA l ‘Procedurali’ (Te. X, La. Te. X, nroff, troff) l l Indicano alla macchina la procedura di formattazione da seguire per un certo testo ‘Generici’ o ‘dichiarativi’ (SGML e discendenti) l Dichiarano la funzione LOGICA del testo
Te. X e La. Te. X The quadratic formula is $-b pm sqrt{b^2 - 4 ac} over 2 a$ end
HTML a SGML XHTML …… WML Math. ML
SGML l l Sviluppato nel 1986 da Charles Goldfarb Obiettivo: sviluppare uno standard per l’INTERSCAMBIO di testi Consente di definire marcatori (‘TAGS’) che permettono di strutturare un testo ed i loro ATTRIBUTI Utilizzato per: l l BNC OED
STRUTTURA SGML NEL BNC ATTRIBUTO
DTD l La specifica degli elementi e dei loro attributi in un documento SGML costituisce la DEFINIZIONE DEL TIPO DI DOCUMENTO o DTD
HTML l l Un linguaggio di marcatura basato su SGML (una DTD SGML) Tipo di elementi e’ fissato
" src="http://present5.com/presentation/0b348da00f82b79de9243b32b810719d/image-11.jpg" alt="LINGUAGGI DI MARCATURA: HTML " />
LINGUAGGI DI MARCATURA: HTML
Hello, World!
XML l l Una versione semplificata di SGML sviluppata dal W 3 C Come in SGML, ed a differenza di HTML, le TAG non sono predefinite ma definite usando un DTD o SCHEMA
ALBERI l I documenti SGML, HTML ed XML hanno una struttura ad ALBERO
DOCUMENTI XML HANNO UNA STRUTTURA AD ALBERO Must have a UNIQUE root element
LA STRUTTURA AD ALBERO DEI DOCUMENTI HTML (ED XML)
Hello, World!
LA STRUTTURA AD ALBERO DEI DOCUMENTI HTML html head title body p
ACCESSO AD UN ALBERO html figlie madre head title body p
XML PER LA STRUTTURA LOGICA DI TESTI
ALBERI + ATTRIBUTI IN XML poem title = Paradise Lost author = jm year= 1667 verse Seest thou yon dreary Plain, forlorn and wild, verse
ATTRIBUTI l Elements can contain one or more attributes
BASI DATI IN XML: RUBRICA
RUBRICA COME ALBERO
TEXT ENCODING INITIATIVE l Un’iniziativa internazionale per sviluppare standards per l’archiviazione di testi Inizi: 1987 Standard basato su SGML agli inizi, ora XML l Definizione: l l l http: //www. tei-c. org/release/doc/tei-p 5 -doc/en/Guidelines. pdf
TESTI IN FORMATO TEI
TEXT ENCODING INITIATIVE l l una testata TEI, codificata come
TEI Header
TEI HEADER: title. Stmt
TEI HEADER: publication. Stmt
KING LEAR IN FORMATO PROJECT GUTENBERG Kent. Now by Apollo, king, Thou swear'st thy gods in vain. Lear. O vassal! miscreant! [Laying his hand on his sword. ] Alb. and Corn. Dear sir, forbear! Kent. Do; Kill thy physician, and the fee bestow Upon the foul disease. Revoke thy gift, Or, whilst I can vent clamour from my throat, I'll tell thee thou dost evil.
Now by Apollo, king, O vassal! miscreant!
KING LEAR IN FORMATO TEI
Thou swear'st thy gods in vain.
Dear sir, forbear! Do;
Kill thy physician, and the fee bestow
Upon the foul disease. Revoke thy gift,
Or, whilst I can vent clamour from my throat,
I'll tell thee thou dost evil.
TEI: JANE EYRE CHAPTER 38 READER, I married him. A quiet wedding we had: he and I, the par- son and clerk, were alone present. When we got back from church, I went into the kitchen of the manor-house, where Mary was cooking the dinner, and John cleaning the knives, and I said – 'Mary, I have been married to Mr Rochester this morning. ' The housekeeper and her husband were of that decent, phlegmatic order of people, to whom one may at any time safely communicate a remarkable piece of news without incurring the danger of having one's ears pierced by some shrill ejaculation and subsequently stunned by a torrent of wordy wonderment. Mary did look up, and she did stare at me; the ladle with which she was basting a pair of chickens roasting at the fire, did for some three minutes hang suspended in air, and for the same space of time John's knives also had rest from the polishing process; but Mary, bending again over the roast, said only --
Reader, I married him. A quiet" src="http://present5.com/presentation/0b348da00f82b79de9243b32b810719d/image-35.jpg" alt="Text markup
Reader, I married him. A quiet" />
Text markup
Reader, I married him. A quiet wedding we had: he and I, the parson and clerk, were alone present. When we got back from church, I went into the kitchen of the manor-house, where Mary was cooking the dinner, and John cleaning the knives, and I said —
Mary, I have been married to Mr Rochester this morning.
The housekeeper and her husband were of that decent, phlegmatic order of people, to whom one may at any time safely communicate a remarkable piece of news without incurring the danger of having one's ears pierced by some shrill ejaculation and subsequently stunned by a torrent of wordy wonderment. Mary did look up, …
ARCHIVI BASATI SULLA TEI l Biblioteca Italiana: l l Electronic Text Center: l l etext. lib. virginia. edu Humanities Text Initiative: l l www. bibliotecaitaliana. it www. hti. umich. edu Oxford Text Archive l ota. ahds. ac. uk
LA BIBLIOTECA ITALIANA
XML – DTD – XSL Un file XML specifica il contenuto Un DTD o SCHEMA specifica la SINTASSI Un file XSL specifica come VISUALIZZARE
IDEE PRINCIPALI LEZIONE DI OGGI l l Linguaggi di marcatura XML l l Struttura ad albero Attributi Text Encoding Initiative Archivi basati sulla TEI
LETTURE l l Tomasi, cap. 4 Linguaggi di Marcatura XML TEI: l Tutorials: l Gentle introduction to XML § http: //www. tei-c. org/release/doc/tei-p 5 doc/en/html/SG. html l TEI-LITE l http: //www. tei-c. org/Guidelines/Customization/Lite/teiu 5_split_en. html
Мы удаляем страницу по первому запросу с достаточным набором данных, указывающих на ваше авторство. Мы также можем оставить страницу, явно указав ваше авторство (страницы полезны всем пользователям рунета и не несут цели нарушения авторских прав). Если такой вариант возможен, пожалуйста, укажите об этом.
