Informatica per le discipline umanistiche 2 – lezione 13 13.pdf · A processor in a computer is...

35
Informatica per le discipline umanistiche 2 – lezione 13 –

Transcript of Informatica per le discipline umanistiche 2 – lezione 13 13.pdf · A processor in a computer is...

Page 1: Informatica per le discipline umanistiche 2 – lezione 13 13.pdf · A processor in a computer is also called a chip. A chip is the most important part in a computer, because it is

Informatica per

le discipline umanistiche 2– lezione 13 –

Page 2: Informatica per le discipline umanistiche 2 – lezione 13 13.pdf · A processor in a computer is also called a chip. A chip is the most important part in a computer, because it is

Ancora qualche considerazione

sul text mining…

Page 3: Informatica per le discipline umanistiche 2 – lezione 13 13.pdf · A processor in a computer is also called a chip. A chip is the most important part in a computer, because it is

Text summarization

Dato un testo, se ne fornisce un breve riassunto basato sulle parole più frequentemente usate (a parte quelle non significative, come “il” o “di” o “e”, chiamate stopword).

Esempio:

Si è detto che la text summarization non è considerata text mining in senso stretto perché si effettua su un documento solo e non cerca collegamenti tra diversi contenuti.

Si tratta comunque di elaborazione automatica di testo.

Si tratta comunque di elaborazione automatica di testo.

Page 4: Informatica per le discipline umanistiche 2 – lezione 13 13.pdf · A processor in a computer is also called a chip. A chip is the most important part in a computer, because it is

A processor in a computer is also called a chip. A chip is the most important part in a computer, because it is the device that performs all the operations. Even when you type “potato” on the screen, the chip is involved.

Consideriamo il seguente testo.

Analizziamolo con la tecnica della text summarization e contiamo le parole più frequenti, ignorando le stop word e punteggiatura.

Page 5: Informatica per le discipline umanistiche 2 – lezione 13 13.pdf · A processor in a computer is also called a chip. A chip is the most important part in a computer, because it is

processor 1

system 1

computer 1

chip 3

potato 1

called 1

important 1

part 1

performs 1

operations 1

type 1

screen 1

involved 1

device 1

you 1

A processor in a computer is also called a chip. A chip is the most important part in a computer, because it is the device that performs all the operations. Even when you type “potato” on the screen, the chip is involved.

Come si fa a capire lʼargomento del testo con la frequenza delle parole?

Page 6: Informatica per le discipline umanistiche 2 – lezione 13 13.pdf · A processor in a computer is also called a chip. A chip is the most important part in a computer, because it is

processor 1

system 1

computer 1

chip 3

potato 1

called 1

important 1

part 1

performs 1

operations 1

type 1

screen 1

involved 1

device 1

you 1

A processor in a computer is also called a chip. A chip is the most important part in a computer, because it is the device that performs all the operations. Even when you type “potato” on the screen, the chip is involved.

Consideriamo la parola più frequente.

Page 7: Informatica per le discipline umanistiche 2 – lezione 13 13.pdf · A processor in a computer is also called a chip. A chip is the most important part in a computer, because it is

chip 3

computer chip potato chip

Problema: i sinonimi

Page 8: Informatica per le discipline umanistiche 2 – lezione 13 13.pdf · A processor in a computer is also called a chip. A chip is the most important part in a computer, because it is

Facendo una ricerca su Google si scopre che ʻchipʼ può essere addirittura un acronimo.

Page 9: Informatica per le discipline umanistiche 2 – lezione 13 13.pdf · A processor in a computer is also called a chip. A chip is the most important part in a computer, because it is

Come affrontare il problema?

Il problema di capire lʼargomento di cui tratta un testo è molto importante per poter individuare tale testo in mezzo ad altri, come ad esempio in una ricerca in internet.

Page 10: Informatica per le discipline umanistiche 2 – lezione 13 13.pdf · A processor in a computer is also called a chip. A chip is the most important part in a computer, because it is

Soluzione 1: affidarsi a ricerche più precise, con più parole chiave.

Page 11: Informatica per le discipline umanistiche 2 – lezione 13 13.pdf · A processor in a computer is also called a chip. A chip is the most important part in a computer, because it is

Eʼ la soluzione più semplice, e funziona nella maggior parte dei casi.

Ma non in tutti.

Page 12: Informatica per le discipline umanistiche 2 – lezione 13 13.pdf · A processor in a computer is also called a chip. A chip is the most important part in a computer, because it is

processor 1

system 1

computer 1

chip 3

potato 1

called 1

important 1

part 1

performs 1

operations 1

type 1

screen 1

involved 1

device 1

you 1

A processor in a computer is also called a chip. A chip is the most important part in a computer, because it is the device that performs all the operations. Even when you type “potato” on the screen, the chip is involved.

Il problema è che, nel testo, ʻcomputerʼ e ʻpotatoʼ sono frequenti nella stessa misura.

Page 13: Informatica per le discipline umanistiche 2 – lezione 13 13.pdf · A processor in a computer is also called a chip. A chip is the most important part in a computer, because it is

Questo sembra essere un finto problema.

Infatti…

Page 14: Informatica per le discipline umanistiche 2 – lezione 13 13.pdf · A processor in a computer is also called a chip. A chip is the most important part in a computer, because it is

processor 1

system 1

computer 1

chip 3

potato 1

called 1

important 1

part 1

performs 1

operations 1

type 1

screen 1

involved 1

device 1

you 1

A processor in a computer is also called a chip. A chip is the most important part in a computer, because it is the device that performs all the operations. Even when you type “potato” on the screen, the chip is involved.

Esaminando le altre parole presenti, è chiaro che si sta parlando del computer chip e non della potato chip.

Page 15: Informatica per le discipline umanistiche 2 – lezione 13 13.pdf · A processor in a computer is also called a chip. A chip is the most important part in a computer, because it is

In realtà…

Page 16: Informatica per le discipline umanistiche 2 – lezione 13 13.pdf · A processor in a computer is also called a chip. A chip is the most important part in a computer, because it is

processor 1

system 1

computer 1

chip 3

potato 1

called 1

important 1

part 1

performs 1

operations 1

type 1

screen 1

involved 1

device 1

you 1

A processor in a computer is also called a chip. A chip is the most important part in a computer, because it is the device that performs all the operations. Even when you type “potato” on the screen, the chip is involved.

Noi riusciamo a stabilire che le parole ʻprocessorʼ, ʻdeviceʼ e tante altre parole del testo appartengono allo stesso dominio di ʻcomputerʼ. Ma come facciamo? Ne sfruttiamo il significato.

Page 17: Informatica per le discipline umanistiche 2 – lezione 13 13.pdf · A processor in a computer is also called a chip. A chip is the most important part in a computer, because it is

Sappiamo bene i limiti dei computer in fatto di significato.

ʻProcessorʼ e ʻdeviceʼ sono

termini informatici.

8

Page 18: Informatica per le discipline umanistiche 2 – lezione 13 13.pdf · A processor in a computer is also called a chip. A chip is the most important part in a computer, because it is

Inoltre…

Page 19: Informatica per le discipline umanistiche 2 – lezione 13 13.pdf · A processor in a computer is also called a chip. A chip is the most important part in a computer, because it is

A new brand of chips, called ʻScreenʼ has become available, made from the best potatoes in England. It is marketed to appeal to a IT-oriented audience, and has computers, processors, and all sorts of devices depicted on the package. Market research has shown that people in IT, especially programmers, are large consumers of chips.

Naturalmente lʼesempio è poco realistico, ma mostra i limiti dellʼanalisi di un testo basato esclusivamente sul conteggio dei vocaboli: funziona molto spesso, ma non in tutti i casi.

Page 20: Informatica per le discipline umanistiche 2 – lezione 13 13.pdf · A processor in a computer is also called a chip. A chip is the most important part in a computer, because it is

Per elaborare una soluzione che funzioni in tutti i casi, dovremmo riprodurre la classificazione degli argomenti, che un essere umano solitamente fa, in un computer.

ʻProcessorʼ e ʻdeviceʼ sono

termini informatici.

8

Page 21: Informatica per le discipline umanistiche 2 – lezione 13 13.pdf · A processor in a computer is also called a chip. A chip is the most important part in a computer, because it is

Lʼesperimento mentale della stanza cinese di Searle vuole dimostrare che un calcolatore che elabora simboli in maniera sintattica non può comprendere la semantica delle parole rappresentate da questi simboli.

Page 22: Informatica per le discipline umanistiche 2 – lezione 13 13.pdf · A processor in a computer is also called a chip. A chip is the most important part in a computer, because it is

Il computer tratta solo simboli in maniera sintattica.

Vogliamo che il computer tratti anche la semantica.

Deve esserci un modo di esprimere la semantica in maniera sintattica.

Sembra una cosa insensata.Eppure…

Page 23: Informatica per le discipline umanistiche 2 – lezione 13 13.pdf · A processor in a computer is also called a chip. A chip is the most important part in a computer, because it is

Web 2.0 1.0Il termine “Web 2.0”, che abbiamo visto utilizzato per descrivere il web “sociale”, in cui gli utenti sono anche creatori di contenuti e lʼinterazione svolge un ruolo fondamentale, è stato in realtà originariamente introdotto con un altro significato. Esiste insomma una prima versione del Web 2.0.

Page 24: Informatica per le discipline umanistiche 2 – lezione 13 13.pdf · A processor in a computer is also called a chip. A chip is the most important part in a computer, because it is

Semantic Web

La prima versione del Web 2.0 è nota anche come semantic Web, o Web semantico, appunto perché si prefiggeva di arricchire internet con tecniche per la trattazione automatica del significato.Lʼidea è stata introdotta da colui che viene considerato come lʼinventore del Web 1.0: Tim Berners-Lee.

Page 25: Informatica per le discipline umanistiche 2 – lezione 13 13.pdf · A processor in a computer is also called a chip. A chip is the most important part in a computer, because it is

Tim Berners-Lee

Page 26: Informatica per le discipline umanistiche 2 – lezione 13 13.pdf · A processor in a computer is also called a chip. A chip is the most important part in a computer, because it is

Lʼidea di base del Semantic Web

tipo di entitànel mondo

Cat

sequenza di caratteri

Anziché affidarsi solo alla mente dellʼutente Web per creare il legame tra la sintassi dei simboli e la loro semantica…

Page 27: Informatica per le discipline umanistiche 2 – lezione 13 13.pdf · A processor in a computer is also called a chip. A chip is the most important part in a computer, because it is

Lʼidea di base del Semantic Web

…usare dei simboli aggiuntivi, sotto forma di marcature, che rimandano a unʼontologia (simile a un vocabolario, in cui i concetti sono organizzati secondo classi di appartenenza).

termine

fine marcatura

inizio marcatura

Resource Description Framework: data model dei metadati come ʻabout ̓

Indirizzo della parte dellʼontologia dove viene spiegato il concetto espresso dal termine “Cat”

Page 28: Informatica per le discipline umanistiche 2 – lezione 13 13.pdf · A processor in a computer is also called a chip. A chip is the most important part in a computer, because it is

Resource Description Framework

Eʼ una convenzione che prescrive il modo con cui i dati con cui lavoriamo devono essere descritti, ossia fornisce indicazioni sui metadati: i dati che parlano di dati.

Resource Description Framework: data model dei metadati come ʻabout ̓

Ovviamente, come tutte le convenzioni, lʼRDF deve essere accettato e seguito da tutti i creatori di contenuti Web per poter funzionare.

Page 29: Informatica per le discipline umanistiche 2 – lezione 13 13.pdf · A processor in a computer is also called a chip. A chip is the most important part in a computer, because it is

Semantic Web: problema 1

Tutti gli utenti Web devono seguire unʼunica convenzione su come descrivere i dati presenti nel Web.RDF è una proposta, ma non è stata universalmente accettato.

Page 30: Informatica per le discipline umanistiche 2 – lezione 13 13.pdf · A processor in a computer is also called a chip. A chip is the most important part in a computer, because it is

Le ontologie

Unʼontologia ha lo scopo di definire tutti i concetti appartenenti a un particolare dominio, e di elencare tutte le possibili relazioni tra di essi.

Indirizzo della parte dellʼontologia dove viene spiegato il concetto espresso dal termine “Cat”

Page 31: Informatica per le discipline umanistiche 2 – lezione 13 13.pdf · A processor in a computer is also called a chip. A chip is the most important part in a computer, because it is

Se andiamo a dbpedia.org/resource/Cat troviamo questa descrizione, in svariate lingue.

La descrizione comprende tutti i modi di riferirsi a un gatto nelle lingue presenti, e anche un albero filogenetico.

Page 32: Informatica per le discipline umanistiche 2 – lezione 13 13.pdf · A processor in a computer is also called a chip. A chip is the most important part in a computer, because it is

Semantic Web: problema 2

Per ciascun concetto esistente, tutti gli utenti Web devono essere dʼaccordo sullʼontologia che lo descrive.DBpedia è una proposta, ma non è stata universalmente accettata.

Page 33: Informatica per le discipline umanistiche 2 – lezione 13 13.pdf · A processor in a computer is also called a chip. A chip is the most important part in a computer, because it is

Semantic Web: problema 3

The chicken or the egg.

Page 34: Informatica per le discipline umanistiche 2 – lezione 13 13.pdf · A processor in a computer is also called a chip. A chip is the most important part in a computer, because it is

Il “chicken or the egg problem” si riferisce a una situazione di stallo. Nel caso della gallina e dellʼuovo, la questione si pone come segue: senza lʼuovo, la gallina non può nascere, ma senza una gallina, non si può fare un uovo.

Per quanto riguarda il semantic Web, la questione riguarda il grande lavoro umano necessario per etichettare con le marcature semantiche tutti i concetti presenti nelle pagine Web esistenti e in quelle future. Tale lavoro chiaramente non può essere automatizzato, perché presuppone che i computer conoscano già il significato delle parole. Riferito al semantic Web, quindi, il “chicken or the egg problem” descrive il seguente stallo: nessun produttore di contenuti Web vuole iniziare lʼimpresa titanica di marcarli se non è sicuro che il semantic Web si realizzi davvero; ma perché il semantic Web si realizzi, tutti devono marcare i contenuti che pubblicano.

Page 35: Informatica per le discipline umanistiche 2 – lezione 13 13.pdf · A processor in a computer is also called a chip. A chip is the most important part in a computer, because it is

Quindi?

Il termine “Web 2.0” è stato riciclato per indicare il Web sociale.Il Semantic Web è ora noto come “Web 3.0”, e non si sa se si realizzerà mai.