SlideShare une entreprise Scribd logo
1  sur  22
Information-rich programming in
                  F#




                  Tomas Petricek, University of Cambridge
                   Don Syme and the F# team, Microsoft


ML Workshop (Copenhagen, 13 September, 2012)
The confusion of languages
The confusion of languages
What is a type provider?
DEMO: Accessing World Bank



Comparing university enrollment rate in
  Czech Republic and OECD countries
Problems with data access

Data is not types with members
 Use dynamic languages?

Need to know names of properties
 Use code generation and static languages?

Enormous scale of data sources
 Types need to be generated “on demand”
Components of a type provider

            Type provider

    IDE                  Compiler
IntelliSense for     Type-Check     Compile using
Provided Types     Provided Types   Type Provider
Research problems
Mapping data sources to types
  What is a type? What is a value?

Types are provided on demand
  Cannot generate all indicator types at once!

Representing data source properties as types
  Physical units, provenance, temporal properties

Adapting to schema change
  Type soundness is relative w.r.t. data source changes
Mapping data source to types



Country




  Indicator     Year
Research problems
Mapping data sources to types
  What is a type? What is a value?

Types are provided on demand
  Cannot generate all indicator types at once!

Representing data source properties as types
  Physical units, provenance, temporal properties

Adapting to schema change
  Type soundness is relative w.r.t. data source changes
Gamma, The Forgotten
Standard typing judgments


Gamma on steroids
            Γ = …,   WB.DataContext
  WB.DataContext = Countries : delay (…)
                               Country list

Reducing delayed context
Research problems
Mapping data sources to types
  What is a type? What is a value?

Types are provided on demand
  Cannot generate all indicator types at once!

Representing data source properties as types
  Physical units, provenance, temporal properties

Adapting to schema change
  Type soundness is relative w.r.t. data source changes
DEMO: XML Type Provider



  Working with XML data and
  adapting to schema change
Related Work

Compile-time meta-programming
 Types generated eagerly, not on demand

Dependently typed languages
 Type-level computation in the IO monad??

Multi-stage computations
 Focus on performance vs. data access
For more information

Upcoming technical report
 Don Syme, et al. Strongly-Typed Language
 Support for an Information-Rich World

Workshop on related topics
 Data Driven Functional Programming
 Workshop, Co-located with POPL 2013
Summary

Mismatch between data and types
 Type providers bridge the gap
 Development-time, compile-time & run-time

Interesting future questions
 Relative type safety and schema change
 Capturing meta-data with types
Research problems
Mapping data sources to types
  What is a type? What is a value?

Types are provided on demand
  Cannot generate all indicator types at once!

Representing data source properties as types
  Physical units, provenance, temporal properties

Adapting to schema change
  Type soundness is relative w.r.t. data source changes
DEMO: FreeBase Type Provider



    Working with chemistry data
       and units of measure
Structure of a Simple Provider
[<TypeProvider>]
type SampleTypeProvider(config: TypeProviderConfig) =
  inherit TypeProviderForNamespaces()

 // Define new type Samples.GeneratedType
 let thisAssembly = Assembly.GetExecutingAssembly()
 let providedType = ProvidedTypeDefinition( ... )
 do
   // Add property 'Hello' that just returns a string
   ProvidedProperty
     ( "Hello", typeof<string>, IsStatic = true,
       GetterCode = fun args -> <@@ Runtime.lookup "Hello" @@>)
   |> providedType.AddMember

   // Register the type with the compiler
   this.AddNamespace(namespaceName, [ providedType ])
Compile-Time vs. Run-time

Type Provider



      Runtime API      Provider

                                     Accesses
                                                 Data
                    Generates                   source
             Uses                    Accesses

                     Provided code
Executable
Compile-Time vs. Run-time

Type Provider



      Runtime API      Provider

                                     Accesses
                                                 Data
                    Generates                   source


                     Provided code
Executable
Queries in F#

Can be turned to quotations
    query { for movie in netflix.Titles do
            where (movie.Name.Contains(search))
            select movie }



Extensible query language
    query { for index in Numbers do
            reverse
            takeWhile index > 10 }

Contenu connexe

Tendances

Exposing RDF Archives using Triple Pattern Fragments
Exposing RDF Archives using Triple Pattern FragmentsExposing RDF Archives using Triple Pattern Fragments
Exposing RDF Archives using Triple Pattern FragmentsRuben Taelman
 
Crowdsourcing the Quality of Knowledge Graphs: A DBpedia Study
Crowdsourcing the Quality of Knowledge Graphs:A DBpedia StudyCrowdsourcing the Quality of Knowledge Graphs:A DBpedia Study
Crowdsourcing the Quality of Knowledge Graphs: A DBpedia StudyMaribel Acosta Deibe
 
Sparklis exploration et interrogation de points d'accès sparql par interactio...
Sparklis exploration et interrogation de points d'accès sparql par interactio...Sparklis exploration et interrogation de points d'accès sparql par interactio...
Sparklis exploration et interrogation de points d'accès sparql par interactio...SemWebPro
 
Open ONI and IIIF: NDNP data in an IIIF Viewer
Open ONI and IIIF: NDNP data in an IIIF ViewerOpen ONI and IIIF: NDNP data in an IIIF Viewer
Open ONI and IIIF: NDNP data in an IIIF ViewerKaren Estlund
 
A Closer Look at the Changing Dynamics of DBpedia Mappings
A Closer Look at the Changing Dynamics of DBpedia MappingsA Closer Look at the Changing Dynamics of DBpedia Mappings
A Closer Look at the Changing Dynamics of DBpedia MappingsMaribel Acosta Deibe
 
Newspapers, IIIF, and ALTO
Newspapers, IIIF, and ALTONewspapers, IIIF, and ALTO
Newspapers, IIIF, and ALTOKaren Estlund
 
Creating a FRBRized Data Structure in XML
Creating a FRBRized Data Structure in XMLCreating a FRBRized Data Structure in XML
Creating a FRBRized Data Structure in XMLJenn Riley
 
Oles Petriv “Creating one concept embedding space for persons, brands and new...
Oles Petriv “Creating one concept embedding space for persons, brands and new...Oles Petriv “Creating one concept embedding space for persons, brands and new...
Oles Petriv “Creating one concept embedding space for persons, brands and new...Lviv Startup Club
 
Healthcare Data Management using Domain Specific Languages for Metadata Manag...
Healthcare Data Management using Domain Specific Languages for Metadata Manag...Healthcare Data Management using Domain Specific Languages for Metadata Manag...
Healthcare Data Management using Domain Specific Languages for Metadata Manag...David Milward
 
Entity Retrieval (WSDM 2014 tutorial)
Entity Retrieval (WSDM 2014 tutorial)Entity Retrieval (WSDM 2014 tutorial)
Entity Retrieval (WSDM 2014 tutorial)krisztianbalog
 
Entity Retrieval (SIGIR 2013 tutorial)
Entity Retrieval (SIGIR 2013 tutorial)Entity Retrieval (SIGIR 2013 tutorial)
Entity Retrieval (SIGIR 2013 tutorial)krisztianbalog
 
Link Discovery Tutorial Part III: Benchmarking for Instance Matching Systems
Link Discovery Tutorial Part III: Benchmarking for Instance Matching SystemsLink Discovery Tutorial Part III: Benchmarking for Instance Matching Systems
Link Discovery Tutorial Part III: Benchmarking for Instance Matching SystemsHolistic Benchmarking of Big Linked Data
 
Pattern-based Acquisition of Scientific Entities from Scholarly Article Title...
Pattern-based Acquisition of Scientific Entities from Scholarly Article Title...Pattern-based Acquisition of Scientific Entities from Scholarly Article Title...
Pattern-based Acquisition of Scientific Entities from Scholarly Article Title...Jennifer D'Souza
 

Tendances (20)

Exposing RDF Archives using Triple Pattern Fragments
Exposing RDF Archives using Triple Pattern FragmentsExposing RDF Archives using Triple Pattern Fragments
Exposing RDF Archives using Triple Pattern Fragments
 
Qald 7 at ESWC2017
Qald 7 at ESWC2017Qald 7 at ESWC2017
Qald 7 at ESWC2017
 
QALD-7 Question Answering over Linked Data Challenge
QALD-7 Question Answering over Linked Data ChallengeQALD-7 Question Answering over Linked Data Challenge
QALD-7 Question Answering over Linked Data Challenge
 
Benchmark BIB-R @ TPDL 2016
Benchmark BIB-R @ TPDL 2016Benchmark BIB-R @ TPDL 2016
Benchmark BIB-R @ TPDL 2016
 
Crowdsourcing the Quality of Knowledge Graphs: A DBpedia Study
Crowdsourcing the Quality of Knowledge Graphs:A DBpedia StudyCrowdsourcing the Quality of Knowledge Graphs:A DBpedia Study
Crowdsourcing the Quality of Knowledge Graphs: A DBpedia Study
 
Milex 2010 final
Milex 2010 finalMilex 2010 final
Milex 2010 final
 
Sparklis exploration et interrogation de points d'accès sparql par interactio...
Sparklis exploration et interrogation de points d'accès sparql par interactio...Sparklis exploration et interrogation de points d'accès sparql par interactio...
Sparklis exploration et interrogation de points d'accès sparql par interactio...
 
Open ONI and IIIF: NDNP data in an IIIF Viewer
Open ONI and IIIF: NDNP data in an IIIF ViewerOpen ONI and IIIF: NDNP data in an IIIF Viewer
Open ONI and IIIF: NDNP data in an IIIF Viewer
 
A Closer Look at the Changing Dynamics of DBpedia Mappings
A Closer Look at the Changing Dynamics of DBpedia MappingsA Closer Look at the Changing Dynamics of DBpedia Mappings
A Closer Look at the Changing Dynamics of DBpedia Mappings
 
Newspapers, IIIF, and ALTO
Newspapers, IIIF, and ALTONewspapers, IIIF, and ALTO
Newspapers, IIIF, and ALTO
 
Topical_Facets
Topical_FacetsTopical_Facets
Topical_Facets
 
Creating a FRBRized Data Structure in XML
Creating a FRBRized Data Structure in XMLCreating a FRBRized Data Structure in XML
Creating a FRBRized Data Structure in XML
 
Oles Petriv “Creating one concept embedding space for persons, brands and new...
Oles Petriv “Creating one concept embedding space for persons, brands and new...Oles Petriv “Creating one concept embedding space for persons, brands and new...
Oles Petriv “Creating one concept embedding space for persons, brands and new...
 
Healthcare Data Management using Domain Specific Languages for Metadata Manag...
Healthcare Data Management using Domain Specific Languages for Metadata Manag...Healthcare Data Management using Domain Specific Languages for Metadata Manag...
Healthcare Data Management using Domain Specific Languages for Metadata Manag...
 
Link Discovery Tutorial Introduction
Link Discovery Tutorial IntroductionLink Discovery Tutorial Introduction
Link Discovery Tutorial Introduction
 
Entity Retrieval (WSDM 2014 tutorial)
Entity Retrieval (WSDM 2014 tutorial)Entity Retrieval (WSDM 2014 tutorial)
Entity Retrieval (WSDM 2014 tutorial)
 
Analyzing poetry databases to develop a metadata application profile. Why eac...
Analyzing poetry databases to develop a metadata application profile. Why eac...Analyzing poetry databases to develop a metadata application profile. Why eac...
Analyzing poetry databases to develop a metadata application profile. Why eac...
 
Entity Retrieval (SIGIR 2013 tutorial)
Entity Retrieval (SIGIR 2013 tutorial)Entity Retrieval (SIGIR 2013 tutorial)
Entity Retrieval (SIGIR 2013 tutorial)
 
Link Discovery Tutorial Part III: Benchmarking for Instance Matching Systems
Link Discovery Tutorial Part III: Benchmarking for Instance Matching SystemsLink Discovery Tutorial Part III: Benchmarking for Instance Matching Systems
Link Discovery Tutorial Part III: Benchmarking for Instance Matching Systems
 
Pattern-based Acquisition of Scientific Entities from Scholarly Article Title...
Pattern-based Acquisition of Scientific Entities from Scholarly Article Title...Pattern-based Acquisition of Scientific Entities from Scholarly Article Title...
Pattern-based Acquisition of Scientific Entities from Scholarly Article Title...
 

En vedette

Tele3113 tut3
Tele3113 tut3Tele3113 tut3
Tele3113 tut3Vin Voro
 
Worshop
WorshopWorshop
Worshopoiwan
 
Tele3113 tut5
Tele3113 tut5Tele3113 tut5
Tele3113 tut5Vin Voro
 
19 structured files
19 structured files19 structured files
19 structured filesashish61_scs
 
Tele3113 tut1
Tele3113 tut1Tele3113 tut1
Tele3113 tut1Vin Voro
 
Design Decisions Securities Market
Design Decisions Securities MarketDesign Decisions Securities Market
Design Decisions Securities MarketSandra Wills
 
Kwik Klik Hoarding Systems Presentation
Kwik Klik Hoarding Systems PresentationKwik Klik Hoarding Systems Presentation
Kwik Klik Hoarding Systems PresentationJohnWhaites
 

En vedette (8)

Tele3113 tut3
Tele3113 tut3Tele3113 tut3
Tele3113 tut3
 
Worshop
WorshopWorshop
Worshop
 
Tele3113 tut5
Tele3113 tut5Tele3113 tut5
Tele3113 tut5
 
19 structured files
19 structured files19 structured files
19 structured files
 
Lect08
Lect08Lect08
Lect08
 
Tele3113 tut1
Tele3113 tut1Tele3113 tut1
Tele3113 tut1
 
Design Decisions Securities Market
Design Decisions Securities MarketDesign Decisions Securities Market
Design Decisions Securities Market
 
Kwik Klik Hoarding Systems Presentation
Kwik Klik Hoarding Systems PresentationKwik Klik Hoarding Systems Presentation
Kwik Klik Hoarding Systems Presentation
 

Similaire à Information-rich programming in F# (ML Workshop 2012)

Consuming Data with F# Type Providers
Consuming Data with F# Type ProvidersConsuming Data with F# Type Providers
Consuming Data with F# Type ProvidersRachel Reese
 
Language Server Protocol - Why the Hype?
Language Server Protocol - Why the Hype?Language Server Protocol - Why the Hype?
Language Server Protocol - Why the Hype?mikaelbarbero
 
Integrating Xtext Language Server support in Visual Studio Code
Integrating Xtext Language Server support in Visual Studio CodeIntegrating Xtext Language Server support in Visual Studio Code
Integrating Xtext Language Server support in Visual Studio CodeKarsten Thoms
 
F# Type Provider for R Statistical Platform
F# Type Provider for R Statistical PlatformF# Type Provider for R Statistical Platform
F# Type Provider for R Statistical PlatformHoward Mansell
 
Accessing loosely structured data from F# and C#
Accessing loosely structured data from F# and C#Accessing loosely structured data from F# and C#
Accessing loosely structured data from F# and C#Tomas Petricek
 
michael hamilton legal database design presentation 3 new york
michael hamilton legal database design presentation 3 new yorkmichael hamilton legal database design presentation 3 new york
michael hamilton legal database design presentation 3 new yorkmichaelhamilton
 
Multi-language Content Discovery Through Entity Driven Search
Multi-language Content Discovery Through Entity Driven SearchMulti-language Content Discovery Through Entity Driven Search
Multi-language Content Discovery Through Entity Driven SearchAlessandro Benedetti
 
Java 5 PSM for DDS: Revised Submission (out of date)
Java 5 PSM for DDS: Revised Submission (out of date)Java 5 PSM for DDS: Revised Submission (out of date)
Java 5 PSM for DDS: Revised Submission (out of date)Rick Warren
 
Adri Jovin - Semantic Web
Adri Jovin - Semantic WebAdri Jovin - Semantic Web
Adri Jovin - Semantic WebAdri Jovin
 
Maintenance of Dynamically vs. Statically typed Languages
Maintenance of Dynamically vs. Statically typed LanguagesMaintenance of Dynamically vs. Statically typed Languages
Maintenance of Dynamically vs. Statically typed LanguagesAmin Bandeali
 
Functional Requirements for an Interlinear Text Editor
Functional Requirements for an Interlinear Text EditorFunctional Requirements for an Interlinear Text Editor
Functional Requirements for an Interlinear Text EditorBaden Hughes
 
Language Engineering With Xtext
Language Engineering With XtextLanguage Engineering With Xtext
Language Engineering With XtextSven Efftinge
 
Creating Domain Specific Languages in F#
Creating Domain Specific Languages in F#Creating Domain Specific Languages in F#
Creating Domain Specific Languages in F#Tomas Petricek
 
Compiler Construction | Lecture 17 | Beyond Compiler Construction
Compiler Construction | Lecture 17 | Beyond Compiler ConstructionCompiler Construction | Lecture 17 | Beyond Compiler Construction
Compiler Construction | Lecture 17 | Beyond Compiler ConstructionEelco Visser
 
Multi-language Content Discovery Through Entity Driven Search: Presented by A...
Multi-language Content Discovery Through Entity Driven Search: Presented by A...Multi-language Content Discovery Through Entity Driven Search: Presented by A...
Multi-language Content Discovery Through Entity Driven Search: Presented by A...Lucidworks
 
F# Type Providers in Depth
F# Type Providers in DepthF# Type Providers in Depth
F# Type Providers in DepthTomas Petricek
 
[DSC Europe 23] Paweł Ekk-Cierniakowski - Video transcription with deep learn...
[DSC Europe 23] Paweł Ekk-Cierniakowski - Video transcription with deep learn...[DSC Europe 23] Paweł Ekk-Cierniakowski - Video transcription with deep learn...
[DSC Europe 23] Paweł Ekk-Cierniakowski - Video transcription with deep learn...DataScienceConferenc1
 

Similaire à Information-rich programming in F# (ML Workshop 2012) (20)

Consuming Data with F# Type Providers
Consuming Data with F# Type ProvidersConsuming Data with F# Type Providers
Consuming Data with F# Type Providers
 
Language Server Protocol - Why the Hype?
Language Server Protocol - Why the Hype?Language Server Protocol - Why the Hype?
Language Server Protocol - Why the Hype?
 
Integrating Xtext Language Server support in Visual Studio Code
Integrating Xtext Language Server support in Visual Studio CodeIntegrating Xtext Language Server support in Visual Studio Code
Integrating Xtext Language Server support in Visual Studio Code
 
F# Type Provider for R Statistical Platform
F# Type Provider for R Statistical PlatformF# Type Provider for R Statistical Platform
F# Type Provider for R Statistical Platform
 
Accessing loosely structured data from F# and C#
Accessing loosely structured data from F# and C#Accessing loosely structured data from F# and C#
Accessing loosely structured data from F# and C#
 
michael hamilton legal database design presentation 3 new york
michael hamilton legal database design presentation 3 new yorkmichael hamilton legal database design presentation 3 new york
michael hamilton legal database design presentation 3 new york
 
seo tutorial
seo tutorialseo tutorial
seo tutorial
 
Multi-language Content Discovery Through Entity Driven Search
Multi-language Content Discovery Through Entity Driven SearchMulti-language Content Discovery Through Entity Driven Search
Multi-language Content Discovery Through Entity Driven Search
 
Java 5 PSM for DDS: Revised Submission (out of date)
Java 5 PSM for DDS: Revised Submission (out of date)Java 5 PSM for DDS: Revised Submission (out of date)
Java 5 PSM for DDS: Revised Submission (out of date)
 
Adri Jovin - Semantic Web
Adri Jovin - Semantic WebAdri Jovin - Semantic Web
Adri Jovin - Semantic Web
 
NetBase API Presentation
NetBase API PresentationNetBase API Presentation
NetBase API Presentation
 
Maintenance of Dynamically vs. Statically typed Languages
Maintenance of Dynamically vs. Statically typed LanguagesMaintenance of Dynamically vs. Statically typed Languages
Maintenance of Dynamically vs. Statically typed Languages
 
.Net Session Overview
.Net Session Overview.Net Session Overview
.Net Session Overview
 
Functional Requirements for an Interlinear Text Editor
Functional Requirements for an Interlinear Text EditorFunctional Requirements for an Interlinear Text Editor
Functional Requirements for an Interlinear Text Editor
 
Language Engineering With Xtext
Language Engineering With XtextLanguage Engineering With Xtext
Language Engineering With Xtext
 
Creating Domain Specific Languages in F#
Creating Domain Specific Languages in F#Creating Domain Specific Languages in F#
Creating Domain Specific Languages in F#
 
Compiler Construction | Lecture 17 | Beyond Compiler Construction
Compiler Construction | Lecture 17 | Beyond Compiler ConstructionCompiler Construction | Lecture 17 | Beyond Compiler Construction
Compiler Construction | Lecture 17 | Beyond Compiler Construction
 
Multi-language Content Discovery Through Entity Driven Search: Presented by A...
Multi-language Content Discovery Through Entity Driven Search: Presented by A...Multi-language Content Discovery Through Entity Driven Search: Presented by A...
Multi-language Content Discovery Through Entity Driven Search: Presented by A...
 
F# Type Providers in Depth
F# Type Providers in DepthF# Type Providers in Depth
F# Type Providers in Depth
 
[DSC Europe 23] Paweł Ekk-Cierniakowski - Video transcription with deep learn...
[DSC Europe 23] Paweł Ekk-Cierniakowski - Video transcription with deep learn...[DSC Europe 23] Paweł Ekk-Cierniakowski - Video transcription with deep learn...
[DSC Europe 23] Paweł Ekk-Cierniakowski - Video transcription with deep learn...
 

Plus de Tomas Petricek

Coeffects: A Calculus of Context-Dependent Computation
Coeffects: A Calculus of Context-Dependent ComputationCoeffects: A Calculus of Context-Dependent Computation
Coeffects: A Calculus of Context-Dependent ComputationTomas Petricek
 
F# and Financial Data Making Data Analysis Simple
F# and Financial Data Making Data Analysis SimpleF# and Financial Data Making Data Analysis Simple
F# and Financial Data Making Data Analysis SimpleTomas Petricek
 
Asynchronous programming in F# (QCon 2012)
Asynchronous programming in F# (QCon 2012)Asynchronous programming in F# (QCon 2012)
Asynchronous programming in F# (QCon 2012)Tomas Petricek
 
Queries in general purpose languages
Queries in general purpose languagesQueries in general purpose languages
Queries in general purpose languagesTomas Petricek
 
Docase notation for Haskell
Docase notation for HaskellDocase notation for Haskell
Docase notation for HaskellTomas Petricek
 
Concurrent programming with Agents
Concurrent programming with AgentsConcurrent programming with Agents
Concurrent programming with AgentsTomas Petricek
 

Plus de Tomas Petricek (11)

Coeffects: A Calculus of Context-Dependent Computation
Coeffects: A Calculus of Context-Dependent ComputationCoeffects: A Calculus of Context-Dependent Computation
Coeffects: A Calculus of Context-Dependent Computation
 
F# and Financial Data Making Data Analysis Simple
F# and Financial Data Making Data Analysis SimpleF# and Financial Data Making Data Analysis Simple
F# and Financial Data Making Data Analysis Simple
 
Asynchronous programming in F# (QCon 2012)
Asynchronous programming in F# (QCon 2012)Asynchronous programming in F# (QCon 2012)
Asynchronous programming in F# (QCon 2012)
 
Queries in general purpose languages
Queries in general purpose languagesQueries in general purpose languages
Queries in general purpose languages
 
Docase notation for Haskell
Docase notation for HaskellDocase notation for Haskell
Docase notation for Haskell
 
F# on the Server-Side
F# on the Server-SideF# on the Server-Side
F# on the Server-Side
 
F# Tutorial @ QCon
F# Tutorial @ QConF# Tutorial @ QCon
F# Tutorial @ QCon
 
Teaching F#
Teaching F#Teaching F#
Teaching F#
 
F# in MonoDevelop
F# in MonoDevelopF# in MonoDevelop
F# in MonoDevelop
 
Academia
AcademiaAcademia
Academia
 
Concurrent programming with Agents
Concurrent programming with AgentsConcurrent programming with Agents
Concurrent programming with Agents
 

Dernier

TeamStation AI System Report LATAM IT Salaries 2024
TeamStation AI System Report LATAM IT Salaries 2024TeamStation AI System Report LATAM IT Salaries 2024
TeamStation AI System Report LATAM IT Salaries 2024Lonnie McRorey
 
Artificial intelligence in cctv survelliance.pptx
Artificial intelligence in cctv survelliance.pptxArtificial intelligence in cctv survelliance.pptx
Artificial intelligence in cctv survelliance.pptxhariprasad279825
 
DevoxxFR 2024 Reproducible Builds with Apache Maven
DevoxxFR 2024 Reproducible Builds with Apache MavenDevoxxFR 2024 Reproducible Builds with Apache Maven
DevoxxFR 2024 Reproducible Builds with Apache MavenHervé Boutemy
 
Generative AI for Technical Writer or Information Developers
Generative AI for Technical Writer or Information DevelopersGenerative AI for Technical Writer or Information Developers
Generative AI for Technical Writer or Information DevelopersRaghuram Pandurangan
 
Advanced Computer Architecture – An Introduction
Advanced Computer Architecture – An IntroductionAdvanced Computer Architecture – An Introduction
Advanced Computer Architecture – An IntroductionDilum Bandara
 
TrustArc Webinar - How to Build Consumer Trust Through Data Privacy
TrustArc Webinar - How to Build Consumer Trust Through Data PrivacyTrustArc Webinar - How to Build Consumer Trust Through Data Privacy
TrustArc Webinar - How to Build Consumer Trust Through Data PrivacyTrustArc
 
Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024BookNet Canada
 
Use of FIDO in the Payments and Identity Landscape: FIDO Paris Seminar.pptx
Use of FIDO in the Payments and Identity Landscape: FIDO Paris Seminar.pptxUse of FIDO in the Payments and Identity Landscape: FIDO Paris Seminar.pptx
Use of FIDO in the Payments and Identity Landscape: FIDO Paris Seminar.pptxLoriGlavin3
 
A Journey Into the Emotions of Software Developers
A Journey Into the Emotions of Software DevelopersA Journey Into the Emotions of Software Developers
A Journey Into the Emotions of Software DevelopersNicole Novielli
 
Take control of your SAP testing with UiPath Test Suite
Take control of your SAP testing with UiPath Test SuiteTake control of your SAP testing with UiPath Test Suite
Take control of your SAP testing with UiPath Test SuiteDianaGray10
 
Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)
Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)
Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)Mark Simos
 
The Ultimate Guide to Choosing WordPress Pros and Cons
The Ultimate Guide to Choosing WordPress Pros and ConsThe Ultimate Guide to Choosing WordPress Pros and Cons
The Ultimate Guide to Choosing WordPress Pros and ConsPixlogix Infotech
 
"Debugging python applications inside k8s environment", Andrii Soldatenko
"Debugging python applications inside k8s environment", Andrii Soldatenko"Debugging python applications inside k8s environment", Andrii Soldatenko
"Debugging python applications inside k8s environment", Andrii SoldatenkoFwdays
 
Merck Moving Beyond Passwords: FIDO Paris Seminar.pptx
Merck Moving Beyond Passwords: FIDO Paris Seminar.pptxMerck Moving Beyond Passwords: FIDO Paris Seminar.pptx
Merck Moving Beyond Passwords: FIDO Paris Seminar.pptxLoriGlavin3
 
The Fit for Passkeys for Employee and Consumer Sign-ins: FIDO Paris Seminar.pptx
The Fit for Passkeys for Employee and Consumer Sign-ins: FIDO Paris Seminar.pptxThe Fit for Passkeys for Employee and Consumer Sign-ins: FIDO Paris Seminar.pptx
The Fit for Passkeys for Employee and Consumer Sign-ins: FIDO Paris Seminar.pptxLoriGlavin3
 
DevEX - reference for building teams, processes, and platforms
DevEX - reference for building teams, processes, and platformsDevEX - reference for building teams, processes, and platforms
DevEX - reference for building teams, processes, and platformsSergiu Bodiu
 
The Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptx
The Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptxThe Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptx
The Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptxLoriGlavin3
 
Gen AI in Business - Global Trends Report 2024.pdf
Gen AI in Business - Global Trends Report 2024.pdfGen AI in Business - Global Trends Report 2024.pdf
Gen AI in Business - Global Trends Report 2024.pdfAddepto
 
A Deep Dive on Passkeys: FIDO Paris Seminar.pptx
A Deep Dive on Passkeys: FIDO Paris Seminar.pptxA Deep Dive on Passkeys: FIDO Paris Seminar.pptx
A Deep Dive on Passkeys: FIDO Paris Seminar.pptxLoriGlavin3
 
Time Series Foundation Models - current state and future directions
Time Series Foundation Models - current state and future directionsTime Series Foundation Models - current state and future directions
Time Series Foundation Models - current state and future directionsNathaniel Shimoni
 

Dernier (20)

TeamStation AI System Report LATAM IT Salaries 2024
TeamStation AI System Report LATAM IT Salaries 2024TeamStation AI System Report LATAM IT Salaries 2024
TeamStation AI System Report LATAM IT Salaries 2024
 
Artificial intelligence in cctv survelliance.pptx
Artificial intelligence in cctv survelliance.pptxArtificial intelligence in cctv survelliance.pptx
Artificial intelligence in cctv survelliance.pptx
 
DevoxxFR 2024 Reproducible Builds with Apache Maven
DevoxxFR 2024 Reproducible Builds with Apache MavenDevoxxFR 2024 Reproducible Builds with Apache Maven
DevoxxFR 2024 Reproducible Builds with Apache Maven
 
Generative AI for Technical Writer or Information Developers
Generative AI for Technical Writer or Information DevelopersGenerative AI for Technical Writer or Information Developers
Generative AI for Technical Writer or Information Developers
 
Advanced Computer Architecture – An Introduction
Advanced Computer Architecture – An IntroductionAdvanced Computer Architecture – An Introduction
Advanced Computer Architecture – An Introduction
 
TrustArc Webinar - How to Build Consumer Trust Through Data Privacy
TrustArc Webinar - How to Build Consumer Trust Through Data PrivacyTrustArc Webinar - How to Build Consumer Trust Through Data Privacy
TrustArc Webinar - How to Build Consumer Trust Through Data Privacy
 
Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
 
Use of FIDO in the Payments and Identity Landscape: FIDO Paris Seminar.pptx
Use of FIDO in the Payments and Identity Landscape: FIDO Paris Seminar.pptxUse of FIDO in the Payments and Identity Landscape: FIDO Paris Seminar.pptx
Use of FIDO in the Payments and Identity Landscape: FIDO Paris Seminar.pptx
 
A Journey Into the Emotions of Software Developers
A Journey Into the Emotions of Software DevelopersA Journey Into the Emotions of Software Developers
A Journey Into the Emotions of Software Developers
 
Take control of your SAP testing with UiPath Test Suite
Take control of your SAP testing with UiPath Test SuiteTake control of your SAP testing with UiPath Test Suite
Take control of your SAP testing with UiPath Test Suite
 
Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)
Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)
Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)
 
The Ultimate Guide to Choosing WordPress Pros and Cons
The Ultimate Guide to Choosing WordPress Pros and ConsThe Ultimate Guide to Choosing WordPress Pros and Cons
The Ultimate Guide to Choosing WordPress Pros and Cons
 
"Debugging python applications inside k8s environment", Andrii Soldatenko
"Debugging python applications inside k8s environment", Andrii Soldatenko"Debugging python applications inside k8s environment", Andrii Soldatenko
"Debugging python applications inside k8s environment", Andrii Soldatenko
 
Merck Moving Beyond Passwords: FIDO Paris Seminar.pptx
Merck Moving Beyond Passwords: FIDO Paris Seminar.pptxMerck Moving Beyond Passwords: FIDO Paris Seminar.pptx
Merck Moving Beyond Passwords: FIDO Paris Seminar.pptx
 
The Fit for Passkeys for Employee and Consumer Sign-ins: FIDO Paris Seminar.pptx
The Fit for Passkeys for Employee and Consumer Sign-ins: FIDO Paris Seminar.pptxThe Fit for Passkeys for Employee and Consumer Sign-ins: FIDO Paris Seminar.pptx
The Fit for Passkeys for Employee and Consumer Sign-ins: FIDO Paris Seminar.pptx
 
DevEX - reference for building teams, processes, and platforms
DevEX - reference for building teams, processes, and platformsDevEX - reference for building teams, processes, and platforms
DevEX - reference for building teams, processes, and platforms
 
The Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptx
The Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptxThe Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptx
The Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptx
 
Gen AI in Business - Global Trends Report 2024.pdf
Gen AI in Business - Global Trends Report 2024.pdfGen AI in Business - Global Trends Report 2024.pdf
Gen AI in Business - Global Trends Report 2024.pdf
 
A Deep Dive on Passkeys: FIDO Paris Seminar.pptx
A Deep Dive on Passkeys: FIDO Paris Seminar.pptxA Deep Dive on Passkeys: FIDO Paris Seminar.pptx
A Deep Dive on Passkeys: FIDO Paris Seminar.pptx
 
Time Series Foundation Models - current state and future directions
Time Series Foundation Models - current state and future directionsTime Series Foundation Models - current state and future directions
Time Series Foundation Models - current state and future directions
 

Information-rich programming in F# (ML Workshop 2012)

  • 1. Information-rich programming in F# Tomas Petricek, University of Cambridge Don Syme and the F# team, Microsoft ML Workshop (Copenhagen, 13 September, 2012)
  • 2. The confusion of languages
  • 3. The confusion of languages
  • 4. What is a type provider?
  • 5. DEMO: Accessing World Bank Comparing university enrollment rate in Czech Republic and OECD countries
  • 6. Problems with data access Data is not types with members Use dynamic languages? Need to know names of properties Use code generation and static languages? Enormous scale of data sources Types need to be generated “on demand”
  • 7. Components of a type provider Type provider IDE Compiler IntelliSense for Type-Check Compile using Provided Types Provided Types Type Provider
  • 8. Research problems Mapping data sources to types What is a type? What is a value? Types are provided on demand Cannot generate all indicator types at once! Representing data source properties as types Physical units, provenance, temporal properties Adapting to schema change Type soundness is relative w.r.t. data source changes
  • 9. Mapping data source to types Country Indicator Year
  • 10. Research problems Mapping data sources to types What is a type? What is a value? Types are provided on demand Cannot generate all indicator types at once! Representing data source properties as types Physical units, provenance, temporal properties Adapting to schema change Type soundness is relative w.r.t. data source changes
  • 11. Gamma, The Forgotten Standard typing judgments Gamma on steroids Γ = …, WB.DataContext WB.DataContext = Countries : delay (…) Country list Reducing delayed context
  • 12. Research problems Mapping data sources to types What is a type? What is a value? Types are provided on demand Cannot generate all indicator types at once! Representing data source properties as types Physical units, provenance, temporal properties Adapting to schema change Type soundness is relative w.r.t. data source changes
  • 13. DEMO: XML Type Provider Working with XML data and adapting to schema change
  • 14. Related Work Compile-time meta-programming Types generated eagerly, not on demand Dependently typed languages Type-level computation in the IO monad?? Multi-stage computations Focus on performance vs. data access
  • 15. For more information Upcoming technical report Don Syme, et al. Strongly-Typed Language Support for an Information-Rich World Workshop on related topics Data Driven Functional Programming Workshop, Co-located with POPL 2013
  • 16. Summary Mismatch between data and types Type providers bridge the gap Development-time, compile-time & run-time Interesting future questions Relative type safety and schema change Capturing meta-data with types
  • 17. Research problems Mapping data sources to types What is a type? What is a value? Types are provided on demand Cannot generate all indicator types at once! Representing data source properties as types Physical units, provenance, temporal properties Adapting to schema change Type soundness is relative w.r.t. data source changes
  • 18. DEMO: FreeBase Type Provider Working with chemistry data and units of measure
  • 19. Structure of a Simple Provider [<TypeProvider>] type SampleTypeProvider(config: TypeProviderConfig) = inherit TypeProviderForNamespaces() // Define new type Samples.GeneratedType let thisAssembly = Assembly.GetExecutingAssembly() let providedType = ProvidedTypeDefinition( ... ) do // Add property 'Hello' that just returns a string ProvidedProperty ( "Hello", typeof<string>, IsStatic = true, GetterCode = fun args -> <@@ Runtime.lookup "Hello" @@>) |> providedType.AddMember // Register the type with the compiler this.AddNamespace(namespaceName, [ providedType ])
  • 20. Compile-Time vs. Run-time Type Provider Runtime API Provider Accesses Data Generates source Uses Accesses Provided code Executable
  • 21. Compile-Time vs. Run-time Type Provider Runtime API Provider Accesses Data Generates source Provided code Executable
  • 22. Queries in F# Can be turned to quotations query { for movie in netflix.Titles do where (movie.Name.Contains(search)) select movie } Extensible query language query { for index in Numbers do reverse takeWhile index > 10 }