SlideShare una empresa de Scribd logo
1 de 48
Descargar para leer sin conexión
WHAT IF
YOUR APPLICATION
COULD SPEAK?
Domain-Specific Language concepts, applications and implementation.
An introduction to Language-Driven Development.
Marcos Vinicius
@bymarkone
Imagine you have a problem to solve …
SUPPLY CHAIN MANAGEMENT
The complexity of inter company documents exchange
THE NEEDS
Translate Documents
Transfer Documents
Was not satisfactory for this context - too much work!
Altova MapForce - the best solution we found
Document oriented
data model
Set of rules that
convert an layout to
another
A repository of
identified layouts
Several helper
functions to help
with the task
An idea
to solve
the problem
Will it work?
After three months - Huge architecture effort spent,
not a single functionality, people lost in system complexity
A language with the semantics of the Document Translation
Domain that allowed us to succeed, and to be really faster
We decided to create a…
Domain-
Specific
Language
FileTransfer
Banking
Contract Management
Financial
Accounting
Supply Chain
Lexical
Analysis
Syntax
Semantics
Grammar
Alphabet
A new era arrived
BUSINESS LEVEL
How The Language-Driven Approach Can Change Business
OTHER DSL
!
▫︎A DSL to query Document
▫︎A DSL to program inside Documents
▫︎A DSL to configure Rules for file transfer
▫︎A DSL to configure networks of Documents
▫︎A DSL to configure security and access
META-LANGUAGE
!
▫︎A language that defines a language
▫︎Define name of the objects and verbs of your language
▫︎Define adjective, if they are mandatory, their datatype
▫︎Allows you have feedback of language syntax in parsing
▫︎Validate a language semantically
▫︎Provide auto-generated APIs documentation
▫︎Provide information for client IDEs
LANGUAGE TEMPTING
!
▫︎A feature that allows you to simplify the language that
the end user can access
!
!
!
!
!
▫︎Granular functionality and modularisation
▫︎On Demand combination to build complex operations
define User “bymarkone" with e-mail “bymarkone@tw.com“;
create Account for “bymarkone”;
activate Account, User “bymarkone”;
send confirmation to "bymarkone"
define and activate User "bymarkone"
becomes
BUSINESS SCRIPTING
!
▫︎When we have large amount of tasks
▫︎E.g. Configuring a new account with N users
▫︎E.g. Setting up a system
▫︎E.g. Sending download instructions to several clients
▫︎Speed in implementation of even complex systems
DEMOING
!
▫︎Build N scenarios for demoing you application
▫︎End users can understand the language and play with
scenarios
ANALYSIS LEVEL
Language Oriented Analysis
add User “Robespierre”;
add User “Rosseau”;
!
“Rosseau” invites “Roberpierre”;
“Robespierre" accept invite from “Rosseau"
“Rosseau” create group “Vive la France!” with tag “Liberté, égalité, fraternité”
“Robespierre" post in “Vive la France!”, message “Let's meet next 14th and kill the king!”
!
“Roberpierre" list friends;
“Rosseau" add message "People who know little are usually great talkers, while men who
know much say little”;
!
“Rosseau" add message “I am sorry to inform you all that our friend and compatriot
Roberspierre was guillotined. This bloody revolution is changing out country at a very
high price. ”
Let’s do a Social Network System
ARCHITECTURE
LEVEL
Language Oriented Architecture
API'S
!
▫︎REST API - A set of URL’s (names) and Actions
▫︎Must be expressive
▫︎Limited - beyond crud, has only HTTP verbs
▫︎With a rich language is hard to draw an API that is as rich
▫︎Expose and API (it can be rest) for language processing
USER EXPERIENCE - UX
!
▫︎Should be build in top of the language
▫︎We don’t care how modern and visual is the design, as
long as it talks the domain language
▫︎E.g. SQL is a DSL on data query and manipulation - how
many UI’s are built in top of that?
▫︎Will an editor with auto-complete and validation work?
TESTING
!
▫︎Unit, integration, component and contract test the
application (independent of the language)
▫︎Add tests for language processing - parsing and
interpreting
▫︎Add tests for language processing feedback
▫︎Add tests for domain and service executing through DSL
OVERALL ARCHITECTURE
!
▫︎UI Layer
▫︎Web Layer (REST)
▫︎Language Processing Layer
▫︎Domain/Services Layer
▫︎Infrastructure Layer
UI Layer
Web / Rest Layer
Language Processing
Domain Layer
Infrastructure Layer
From Martin Fowler’s DSL
PROCESS LEVEL
COMMUNICATION
!
▫︎The DSL is the language of communication of business
▫︎Devs, QA, BA, PO, Business Specialist, even Stakeholders
▫︎Ubiquitous Language
▫︎“Semantic Meetings” to understand and refine words of
the language, and their meaning
DOMAIN-DRIVEN DESIGN
!
▫︎Important to start the discussion about Domain
meaning - Entities, Services, Aggregates, Value-Objects
▫︎Design and Domain are emergent - they are created/
refactored with the development of the application
▫︎Create the DSL
▫︎Create the Semantic Model - connected to the DSL
▫︎Semantic Model is different than the Domain Model -
the first is a subset of the second.
PROGRAMMING
LEVEL
The fun of building a language
OVERALL OF LANGUAGE PROCESSING
Lexical
Analysis
Parsing
Semantic
Analysis
Text Tokens AST
Abstract
Syntax
Tree
Code
Generation
Semantic

Model
grammar IML;
!
program : (functionDecl | stat | expr)+;
functionDecl : type ID LP formalParams? RP block;
formalParams : formalParam (COMMA formalParam)*;
formalParam : type ID;
type : (DOUBLEDECL | INTDECL | STRINGDECL);
varDecl : type ID (EQUAL expr)? SEMICOLON ;
block : LB stat* RB;
assignment : expr EQUAL expr SEMICOLON;
conditional : IF expr THEN stat (ELSE stat)?;
returnstat : RETURN expr? SEMICOLON;
stat : block
| varDecl
| conditional
| returnstat
| assignment
| expr SEMICOLON
;
expr : functionExpr // f()
| arrayExpr // g[]
| unaryOpExpr
| expr binaryOp
| idExpr
| intExpr
BNF GRAMMARS
ANTLR
LANGUAGE LEVEL
Expanding horizons of our thought
Grammars
Alphabets
Languages
Syntactics
Semantics
Compilers
State Machines
Regular Languages
Context-Free
Grammars
PHILOSOPHICAL
LEVEL
Languages and Thought
“Because language does not mimic the world, you can do things
with it that are impossible under the law of physics. You are a god
in language. You can create. Destroy. Rearrange. Shove words
around however you like. You can make up stories about things
that never happened to people who never existed. You can push a
camel through the eye of a needle. It’s easy if ‘camel' and ‘needle’
are words.
In language, mortality does not tick relentlessly. You can conceive
of yourself as alive forever. Or you can imagine yourself dead. And
then alive again. You can live, die, live, die, live, die, live.”
The First Word: The Search for the Origins of Language
Christine Kenneally
Imaginary
Virtual
Real
Understand the Power of Languages,
Domain-Specific Languages,
for your project, architecture and
business
Language-Driven Development
Define a DSL that is going to represent the whole set of functionalities
that your application communicates with the external world.
Build this DSL in top of your high-level language, this second will
implement the more broad domain logic of your application.
Design your architecture, UX, ubiquitous language, meetings with
business, testing, external APIs… in top of that DSL.
This DSL is going to be the language your application speaks
For questions or suggestions:
!
Marcos Vinicius
@bymarkone
github.com/bymarkone
THANK YOU

Más contenido relacionado

La actualidad más candente

JavaScript Roadmap III - ECMAScript
JavaScript Roadmap III - ECMAScriptJavaScript Roadmap III - ECMAScript
JavaScript Roadmap III - ECMAScriptAswin Barath
 
Coldfusion
ColdfusionColdfusion
ColdfusionRam
 
Javascript Framework Roundup FYB
Javascript Framework Roundup FYBJavascript Framework Roundup FYB
Javascript Framework Roundup FYBnukeevry1
 
Up to speed in domain driven design
Up to speed in domain driven designUp to speed in domain driven design
Up to speed in domain driven designRick van der Arend
 
Php[tek] 2016 - BDD with Behat for Beginners
Php[tek] 2016 - BDD with Behat for BeginnersPhp[tek] 2016 - BDD with Behat for Beginners
Php[tek] 2016 - BDD with Behat for BeginnersAdam Englander
 
Quo vadis, JavaScript? Devday.pl keynote
Quo vadis, JavaScript? Devday.pl keynoteQuo vadis, JavaScript? Devday.pl keynote
Quo vadis, JavaScript? Devday.pl keynoteChristian Heilmann
 
Dynamic Languages In The Enterprise (4developers march 2009)
Dynamic Languages In The Enterprise (4developers march 2009)Dynamic Languages In The Enterprise (4developers march 2009)
Dynamic Languages In The Enterprise (4developers march 2009)Ivo Jansch
 
What is the best programming language for your web product?
What is the best programming language for your web product?What is the best programming language for your web product?
What is the best programming language for your web product?MobiDev
 
Seven ways to be a happier JavaScript developer - NDC Oslo
Seven ways to be a happier JavaScript developer - NDC OsloSeven ways to be a happier JavaScript developer - NDC Oslo
Seven ways to be a happier JavaScript developer - NDC OsloChristian Heilmann
 
Intro to Javascript
Intro to JavascriptIntro to Javascript
Intro to JavascriptKevin Ball
 
Application Development Using Java - DIYComputerScience Course
Application Development Using Java - DIYComputerScience CourseApplication Development Using Java - DIYComputerScience Course
Application Development Using Java - DIYComputerScience Courseparag
 
[JS EXPERIENCE 2018] Os segredos dos pricipais frameworks JS: Vanilla.js - Ig...
[JS EXPERIENCE 2018] Os segredos dos pricipais frameworks JS: Vanilla.js - Ig...[JS EXPERIENCE 2018] Os segredos dos pricipais frameworks JS: Vanilla.js - Ig...
[JS EXPERIENCE 2018] Os segredos dos pricipais frameworks JS: Vanilla.js - Ig...iMasters
 
Hack your carrer : teach yourself coding
Hack your carrer : teach yourself codingHack your carrer : teach yourself coding
Hack your carrer : teach yourself codingWomen Who Code Tokyo
 
There is something about JavaScript - Choose Forum 2014
There is something about JavaScript - Choose Forum 2014There is something about JavaScript - Choose Forum 2014
There is something about JavaScript - Choose Forum 2014jbandi
 
Rails Vs CakePHP
Rails Vs CakePHPRails Vs CakePHP
Rails Vs CakePHPGautam Rege
 
Frontend Development vs Backend Development | Detailed Comparison
Frontend Development vs Backend Development | Detailed ComparisonFrontend Development vs Backend Development | Detailed Comparison
Frontend Development vs Backend Development | Detailed ComparisonMariya James
 
Behavior Driven Education: A Story of Learning ROR
Behavior Driven Education: A Story of Learning RORBehavior Driven Education: A Story of Learning ROR
Behavior Driven Education: A Story of Learning RORSmartLogic
 

La actualidad más candente (19)

JavaScript Roadmap III - ECMAScript
JavaScript Roadmap III - ECMAScriptJavaScript Roadmap III - ECMAScript
JavaScript Roadmap III - ECMAScript
 
Coldfusion
ColdfusionColdfusion
Coldfusion
 
Javascript Framework Roundup FYB
Javascript Framework Roundup FYBJavascript Framework Roundup FYB
Javascript Framework Roundup FYB
 
Introduction to Java Scripting
Introduction to Java ScriptingIntroduction to Java Scripting
Introduction to Java Scripting
 
Up to speed in domain driven design
Up to speed in domain driven designUp to speed in domain driven design
Up to speed in domain driven design
 
Php[tek] 2016 - BDD with Behat for Beginners
Php[tek] 2016 - BDD with Behat for BeginnersPhp[tek] 2016 - BDD with Behat for Beginners
Php[tek] 2016 - BDD with Behat for Beginners
 
Quo vadis, JavaScript? Devday.pl keynote
Quo vadis, JavaScript? Devday.pl keynoteQuo vadis, JavaScript? Devday.pl keynote
Quo vadis, JavaScript? Devday.pl keynote
 
Dynamic Languages In The Enterprise (4developers march 2009)
Dynamic Languages In The Enterprise (4developers march 2009)Dynamic Languages In The Enterprise (4developers march 2009)
Dynamic Languages In The Enterprise (4developers march 2009)
 
What is the best programming language for your web product?
What is the best programming language for your web product?What is the best programming language for your web product?
What is the best programming language for your web product?
 
Seven ways to be a happier JavaScript developer - NDC Oslo
Seven ways to be a happier JavaScript developer - NDC OsloSeven ways to be a happier JavaScript developer - NDC Oslo
Seven ways to be a happier JavaScript developer - NDC Oslo
 
Intro to Javascript
Intro to JavascriptIntro to Javascript
Intro to Javascript
 
Application Development Using Java - DIYComputerScience Course
Application Development Using Java - DIYComputerScience CourseApplication Development Using Java - DIYComputerScience Course
Application Development Using Java - DIYComputerScience Course
 
[JS EXPERIENCE 2018] Os segredos dos pricipais frameworks JS: Vanilla.js - Ig...
[JS EXPERIENCE 2018] Os segredos dos pricipais frameworks JS: Vanilla.js - Ig...[JS EXPERIENCE 2018] Os segredos dos pricipais frameworks JS: Vanilla.js - Ig...
[JS EXPERIENCE 2018] Os segredos dos pricipais frameworks JS: Vanilla.js - Ig...
 
Hack your carrer : teach yourself coding
Hack your carrer : teach yourself codingHack your carrer : teach yourself coding
Hack your carrer : teach yourself coding
 
There is something about JavaScript - Choose Forum 2014
There is something about JavaScript - Choose Forum 2014There is something about JavaScript - Choose Forum 2014
There is something about JavaScript - Choose Forum 2014
 
Rails Vs CakePHP
Rails Vs CakePHPRails Vs CakePHP
Rails Vs CakePHP
 
React Native
React NativeReact Native
React Native
 
Frontend Development vs Backend Development | Detailed Comparison
Frontend Development vs Backend Development | Detailed ComparisonFrontend Development vs Backend Development | Detailed Comparison
Frontend Development vs Backend Development | Detailed Comparison
 
Behavior Driven Education: A Story of Learning ROR
Behavior Driven Education: A Story of Learning RORBehavior Driven Education: A Story of Learning ROR
Behavior Driven Education: A Story of Learning ROR
 

Destacado

Software Kaizen, por Gabriela Guerra e Luiza Souza
Software Kaizen, por Gabriela Guerra e Luiza SouzaSoftware Kaizen, por Gabriela Guerra e Luiza Souza
Software Kaizen, por Gabriela Guerra e Luiza SouzaThoughtworks
 
Javascript toolkit
Javascript toolkitJavascript toolkit
Javascript toolkitThoughtworks
 
Voto-Como-Vamos, por Carlos Vilella, Gabriela Guerra e Nelice Heck
Voto-Como-Vamos, por Carlos Vilella, Gabriela Guerra e Nelice HeckVoto-Como-Vamos, por Carlos Vilella, Gabriela Guerra e Nelice Heck
Voto-Como-Vamos, por Carlos Vilella, Gabriela Guerra e Nelice HeckThoughtworks
 
Projeto de API, por Gilmar P.S
Projeto de API, por Gilmar P.SProjeto de API, por Gilmar P.S
Projeto de API, por Gilmar P.SThoughtworks
 
Protractor - Testando aplicações AngularJS end to end
Protractor - Testando aplicações AngularJS end to endProtractor - Testando aplicações AngularJS end to end
Protractor - Testando aplicações AngularJS end to endDaniel Amorim
 

Destacado (6)

Software Kaizen, por Gabriela Guerra e Luiza Souza
Software Kaizen, por Gabriela Guerra e Luiza SouzaSoftware Kaizen, por Gabriela Guerra e Luiza Souza
Software Kaizen, por Gabriela Guerra e Luiza Souza
 
Javascript toolkit
Javascript toolkitJavascript toolkit
Javascript toolkit
 
Seja Tester Ágil
Seja Tester ÁgilSeja Tester Ágil
Seja Tester Ágil
 
Voto-Como-Vamos, por Carlos Vilella, Gabriela Guerra e Nelice Heck
Voto-Como-Vamos, por Carlos Vilella, Gabriela Guerra e Nelice HeckVoto-Como-Vamos, por Carlos Vilella, Gabriela Guerra e Nelice Heck
Voto-Como-Vamos, por Carlos Vilella, Gabriela Guerra e Nelice Heck
 
Projeto de API, por Gilmar P.S
Projeto de API, por Gilmar P.SProjeto de API, por Gilmar P.S
Projeto de API, por Gilmar P.S
 
Protractor - Testando aplicações AngularJS end to end
Protractor - Testando aplicações AngularJS end to endProtractor - Testando aplicações AngularJS end to end
Protractor - Testando aplicações AngularJS end to end
 

Similar a What if-your-application-could-speak, by Marcos Silveira

Ubiquity: Designing a Multilingual Natural Language Interface
Ubiquity: Designing a Multilingual Natural Language InterfaceUbiquity: Designing a Multilingual Natural Language Interface
Ubiquity: Designing a Multilingual Natural Language InterfaceMichael Yoshitaka Erlewine
 
Better Accessibility with Lex, Polly, and Alexa | AWS Public Sector Summit 2017
Better Accessibility with Lex, Polly, and Alexa | AWS Public Sector Summit 2017Better Accessibility with Lex, Polly, and Alexa | AWS Public Sector Summit 2017
Better Accessibility with Lex, Polly, and Alexa | AWS Public Sector Summit 2017Amazon Web Services
 
Build your own Language - Why and How?
Build your own Language - Why and How?Build your own Language - Why and How?
Build your own Language - Why and How?Markus Voelter
 
Java As A Programming Language
Java As A Programming LanguageJava As A Programming Language
Java As A Programming LanguageJennifer Wright
 
A11Y? I18N? L10N? UTF8? WTF? Understanding the connections between: accessib...
A11Y? I18N? L10N? UTF8? WTF? Understanding the connections between:  accessib...A11Y? I18N? L10N? UTF8? WTF? Understanding the connections between:  accessib...
A11Y? I18N? L10N? UTF8? WTF? Understanding the connections between: accessib...mtoppa
 
Building speech enabled products with Amazon Polly & Amazon Lex
Building speech enabled products with Amazon Polly & Amazon LexBuilding speech enabled products with Amazon Polly & Amazon Lex
Building speech enabled products with Amazon Polly & Amazon LexAmazon Web Services
 
10 tips for a usable website
10 tips for a usable website10 tips for a usable website
10 tips for a usable websiteBart De Waele
 
Google Cloud Platform - Cloud-Native Roadshow Stuttgart
Google Cloud Platform - Cloud-Native Roadshow StuttgartGoogle Cloud Platform - Cloud-Native Roadshow Stuttgart
Google Cloud Platform - Cloud-Native Roadshow StuttgartVMware Tanzu
 
Envisioning the Future of Language Workbenches
Envisioning the Future of Language WorkbenchesEnvisioning the Future of Language Workbenches
Envisioning the Future of Language WorkbenchesMarkus Voelter
 
languagetranslator-211028085026.pptx
languagetranslator-211028085026.pptxlanguagetranslator-211028085026.pptx
languagetranslator-211028085026.pptxMDASIFALI32
 
Stream SQL eventflow visual programming for real programmers presentation
Stream SQL eventflow visual programming for real programmers presentationStream SQL eventflow visual programming for real programmers presentation
Stream SQL eventflow visual programming for real programmers presentationstreambase
 
AWS Artificial Intelligence Day - Toronto
AWS Artificial Intelligence Day - TorontoAWS Artificial Intelligence Day - Toronto
AWS Artificial Intelligence Day - TorontoAmazon Web Services
 
Amazon Web Services - Strategy and Current Offering
Amazon Web Services - Strategy and Current OfferingAmazon Web Services - Strategy and Current Offering
Amazon Web Services - Strategy and Current OfferingAmazon Web Services
 
Google Cloud Platform Munich
Google Cloud Platform MunichGoogle Cloud Platform Munich
Google Cloud Platform MunichVMware Tanzu
 
JavaScript - The new English
JavaScript - The new EnglishJavaScript - The new English
JavaScript - The new EnglishMário Gonçalves
 
Java And Community Support
Java And Community SupportJava And Community Support
Java And Community SupportWilliam Grosso
 
Specification Of The Programming Language Of Java
Specification Of The Programming Language Of JavaSpecification Of The Programming Language Of Java
Specification Of The Programming Language Of JavaKim Moore
 
COMPUTER LANGUAGES AND THERE DIFFERENCE
COMPUTER LANGUAGES AND THERE DIFFERENCE COMPUTER LANGUAGES AND THERE DIFFERENCE
COMPUTER LANGUAGES AND THERE DIFFERENCE Pavan Kalyan
 
English de lenguaje de programacion
English de lenguaje de programacionEnglish de lenguaje de programacion
English de lenguaje de programacionVillalba Griselda
 

Similar a What if-your-application-could-speak, by Marcos Silveira (20)

Ubiquity: Designing a Multilingual Natural Language Interface
Ubiquity: Designing a Multilingual Natural Language InterfaceUbiquity: Designing a Multilingual Natural Language Interface
Ubiquity: Designing a Multilingual Natural Language Interface
 
Better Accessibility with Lex, Polly, and Alexa | AWS Public Sector Summit 2017
Better Accessibility with Lex, Polly, and Alexa | AWS Public Sector Summit 2017Better Accessibility with Lex, Polly, and Alexa | AWS Public Sector Summit 2017
Better Accessibility with Lex, Polly, and Alexa | AWS Public Sector Summit 2017
 
Build your own Language - Why and How?
Build your own Language - Why and How?Build your own Language - Why and How?
Build your own Language - Why and How?
 
Java As A Programming Language
Java As A Programming LanguageJava As A Programming Language
Java As A Programming Language
 
About programming languages
About programming languagesAbout programming languages
About programming languages
 
A11Y? I18N? L10N? UTF8? WTF? Understanding the connections between: accessib...
A11Y? I18N? L10N? UTF8? WTF? Understanding the connections between:  accessib...A11Y? I18N? L10N? UTF8? WTF? Understanding the connections between:  accessib...
A11Y? I18N? L10N? UTF8? WTF? Understanding the connections between: accessib...
 
Building speech enabled products with Amazon Polly & Amazon Lex
Building speech enabled products with Amazon Polly & Amazon LexBuilding speech enabled products with Amazon Polly & Amazon Lex
Building speech enabled products with Amazon Polly & Amazon Lex
 
10 tips for a usable website
10 tips for a usable website10 tips for a usable website
10 tips for a usable website
 
Google Cloud Platform - Cloud-Native Roadshow Stuttgart
Google Cloud Platform - Cloud-Native Roadshow StuttgartGoogle Cloud Platform - Cloud-Native Roadshow Stuttgart
Google Cloud Platform - Cloud-Native Roadshow Stuttgart
 
Envisioning the Future of Language Workbenches
Envisioning the Future of Language WorkbenchesEnvisioning the Future of Language Workbenches
Envisioning the Future of Language Workbenches
 
languagetranslator-211028085026.pptx
languagetranslator-211028085026.pptxlanguagetranslator-211028085026.pptx
languagetranslator-211028085026.pptx
 
Stream SQL eventflow visual programming for real programmers presentation
Stream SQL eventflow visual programming for real programmers presentationStream SQL eventflow visual programming for real programmers presentation
Stream SQL eventflow visual programming for real programmers presentation
 
AWS Artificial Intelligence Day - Toronto
AWS Artificial Intelligence Day - TorontoAWS Artificial Intelligence Day - Toronto
AWS Artificial Intelligence Day - Toronto
 
Amazon Web Services - Strategy and Current Offering
Amazon Web Services - Strategy and Current OfferingAmazon Web Services - Strategy and Current Offering
Amazon Web Services - Strategy and Current Offering
 
Google Cloud Platform Munich
Google Cloud Platform MunichGoogle Cloud Platform Munich
Google Cloud Platform Munich
 
JavaScript - The new English
JavaScript - The new EnglishJavaScript - The new English
JavaScript - The new English
 
Java And Community Support
Java And Community SupportJava And Community Support
Java And Community Support
 
Specification Of The Programming Language Of Java
Specification Of The Programming Language Of JavaSpecification Of The Programming Language Of Java
Specification Of The Programming Language Of Java
 
COMPUTER LANGUAGES AND THERE DIFFERENCE
COMPUTER LANGUAGES AND THERE DIFFERENCE COMPUTER LANGUAGES AND THERE DIFFERENCE
COMPUTER LANGUAGES AND THERE DIFFERENCE
 
English de lenguaje de programacion
English de lenguaje de programacionEnglish de lenguaje de programacion
English de lenguaje de programacion
 

Más de Thoughtworks

Design System as a Product
Design System as a ProductDesign System as a Product
Design System as a ProductThoughtworks
 
Designers, Developers & Dogs
Designers, Developers & DogsDesigners, Developers & Dogs
Designers, Developers & DogsThoughtworks
 
Cloud-first for fast innovation
Cloud-first for fast innovationCloud-first for fast innovation
Cloud-first for fast innovationThoughtworks
 
More impact with flexible teams
More impact with flexible teamsMore impact with flexible teams
More impact with flexible teamsThoughtworks
 
Culture of Innovation
Culture of InnovationCulture of Innovation
Culture of InnovationThoughtworks
 
Developer Experience
Developer ExperienceDeveloper Experience
Developer ExperienceThoughtworks
 
When we design together
When we design togetherWhen we design together
When we design togetherThoughtworks
 
Hardware is hard(er)
Hardware is hard(er)Hardware is hard(er)
Hardware is hard(er)Thoughtworks
 
Customer-centric innovation enabled by cloud
 Customer-centric innovation enabled by cloud Customer-centric innovation enabled by cloud
Customer-centric innovation enabled by cloudThoughtworks
 
Amazon's Culture of Innovation
Amazon's Culture of InnovationAmazon's Culture of Innovation
Amazon's Culture of InnovationThoughtworks
 
When in doubt, go live
When in doubt, go liveWhen in doubt, go live
When in doubt, go liveThoughtworks
 
Don't cross the Rubicon
Don't cross the RubiconDon't cross the Rubicon
Don't cross the RubiconThoughtworks
 
Your test coverage is a lie!
Your test coverage is a lie!Your test coverage is a lie!
Your test coverage is a lie!Thoughtworks
 
Docker container security
Docker container securityDocker container security
Docker container securityThoughtworks
 
Redefining the unit
Redefining the unitRedefining the unit
Redefining the unitThoughtworks
 
Technology Radar Webinar UK - Vol. 22
Technology Radar Webinar UK - Vol. 22Technology Radar Webinar UK - Vol. 22
Technology Radar Webinar UK - Vol. 22Thoughtworks
 
A Tribute to Turing
A Tribute to TuringA Tribute to Turing
A Tribute to TuringThoughtworks
 
Rsa maths worked out
Rsa maths worked outRsa maths worked out
Rsa maths worked outThoughtworks
 

Más de Thoughtworks (20)

Design System as a Product
Design System as a ProductDesign System as a Product
Design System as a Product
 
Designers, Developers & Dogs
Designers, Developers & DogsDesigners, Developers & Dogs
Designers, Developers & Dogs
 
Cloud-first for fast innovation
Cloud-first for fast innovationCloud-first for fast innovation
Cloud-first for fast innovation
 
More impact with flexible teams
More impact with flexible teamsMore impact with flexible teams
More impact with flexible teams
 
Culture of Innovation
Culture of InnovationCulture of Innovation
Culture of Innovation
 
Dual-Track Agile
Dual-Track AgileDual-Track Agile
Dual-Track Agile
 
Developer Experience
Developer ExperienceDeveloper Experience
Developer Experience
 
When we design together
When we design togetherWhen we design together
When we design together
 
Hardware is hard(er)
Hardware is hard(er)Hardware is hard(er)
Hardware is hard(er)
 
Customer-centric innovation enabled by cloud
 Customer-centric innovation enabled by cloud Customer-centric innovation enabled by cloud
Customer-centric innovation enabled by cloud
 
Amazon's Culture of Innovation
Amazon's Culture of InnovationAmazon's Culture of Innovation
Amazon's Culture of Innovation
 
When in doubt, go live
When in doubt, go liveWhen in doubt, go live
When in doubt, go live
 
Don't cross the Rubicon
Don't cross the RubiconDon't cross the Rubicon
Don't cross the Rubicon
 
Error handling
Error handlingError handling
Error handling
 
Your test coverage is a lie!
Your test coverage is a lie!Your test coverage is a lie!
Your test coverage is a lie!
 
Docker container security
Docker container securityDocker container security
Docker container security
 
Redefining the unit
Redefining the unitRedefining the unit
Redefining the unit
 
Technology Radar Webinar UK - Vol. 22
Technology Radar Webinar UK - Vol. 22Technology Radar Webinar UK - Vol. 22
Technology Radar Webinar UK - Vol. 22
 
A Tribute to Turing
A Tribute to TuringA Tribute to Turing
A Tribute to Turing
 
Rsa maths worked out
Rsa maths worked outRsa maths worked out
Rsa maths worked out
 

Último

Scaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationScaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationRadu Cotescu
 
A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)Gabriella Davis
 
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationFrom Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationSafe Software
 
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...Neo4j
 
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Miguel Araújo
 
Presentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreterPresentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreternaman860154
 
Histor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slideHistor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slidevu2urc
 
Artificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and MythsArtificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and MythsJoaquim Jorge
 
Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024The Digital Insurer
 
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Drew Madelung
 
Handwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed textsHandwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed textsMaria Levchenko
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerThousandEyes
 
Tech Trends Report 2024 Future Today Institute.pdf
Tech Trends Report 2024 Future Today Institute.pdfTech Trends Report 2024 Future Today Institute.pdf
Tech Trends Report 2024 Future Today Institute.pdfhans926745
 
Exploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone ProcessorsExploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone Processorsdebabhi2
 
GenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationGenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationMichael W. Hawkins
 
Boost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdfBoost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdfsudhanshuwaghmare1
 
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdfThe Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdfEnterprise Knowledge
 
Automating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps ScriptAutomating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps Scriptwesley chun
 
Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024The Digital Insurer
 
Evaluating the top large language models.pdf
Evaluating the top large language models.pdfEvaluating the top large language models.pdf
Evaluating the top large language models.pdfChristopherTHyatt
 

Último (20)

Scaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationScaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organization
 
A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)
 
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationFrom Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
 
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
 
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
 
Presentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreterPresentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreter
 
Histor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slideHistor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slide
 
Artificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and MythsArtificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and Myths
 
Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024
 
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
 
Handwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed textsHandwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed texts
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected Worker
 
Tech Trends Report 2024 Future Today Institute.pdf
Tech Trends Report 2024 Future Today Institute.pdfTech Trends Report 2024 Future Today Institute.pdf
Tech Trends Report 2024 Future Today Institute.pdf
 
Exploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone ProcessorsExploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone Processors
 
GenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationGenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day Presentation
 
Boost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdfBoost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdf
 
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdfThe Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
 
Automating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps ScriptAutomating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps Script
 
Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024
 
Evaluating the top large language models.pdf
Evaluating the top large language models.pdfEvaluating the top large language models.pdf
Evaluating the top large language models.pdf
 

What if-your-application-could-speak, by Marcos Silveira

  • 1. WHAT IF YOUR APPLICATION COULD SPEAK? Domain-Specific Language concepts, applications and implementation. An introduction to Language-Driven Development. Marcos Vinicius @bymarkone
  • 2. Imagine you have a problem to solve …
  • 3. SUPPLY CHAIN MANAGEMENT The complexity of inter company documents exchange
  • 5. Was not satisfactory for this context - too much work! Altova MapForce - the best solution we found
  • 6. Document oriented data model Set of rules that convert an layout to another A repository of identified layouts Several helper functions to help with the task An idea to solve the problem
  • 7. Will it work? After three months - Huge architecture effort spent, not a single functionality, people lost in system complexity
  • 8. A language with the semantics of the Document Translation Domain that allowed us to succeed, and to be really faster We decided to create a…
  • 10.
  • 11.
  • 12.
  • 13.
  • 14.
  • 15.
  • 16.
  • 17. A new era arrived
  • 18. BUSINESS LEVEL How The Language-Driven Approach Can Change Business
  • 19. OTHER DSL ! ▫︎A DSL to query Document ▫︎A DSL to program inside Documents ▫︎A DSL to configure Rules for file transfer ▫︎A DSL to configure networks of Documents ▫︎A DSL to configure security and access
  • 20. META-LANGUAGE ! ▫︎A language that defines a language ▫︎Define name of the objects and verbs of your language ▫︎Define adjective, if they are mandatory, their datatype ▫︎Allows you have feedback of language syntax in parsing ▫︎Validate a language semantically ▫︎Provide auto-generated APIs documentation ▫︎Provide information for client IDEs
  • 21. LANGUAGE TEMPTING ! ▫︎A feature that allows you to simplify the language that the end user can access ! ! ! ! ! ▫︎Granular functionality and modularisation ▫︎On Demand combination to build complex operations define User “bymarkone" with e-mail “bymarkone@tw.com“; create Account for “bymarkone”; activate Account, User “bymarkone”; send confirmation to "bymarkone" define and activate User "bymarkone" becomes
  • 22. BUSINESS SCRIPTING ! ▫︎When we have large amount of tasks ▫︎E.g. Configuring a new account with N users ▫︎E.g. Setting up a system ▫︎E.g. Sending download instructions to several clients ▫︎Speed in implementation of even complex systems
  • 23. DEMOING ! ▫︎Build N scenarios for demoing you application ▫︎End users can understand the language and play with scenarios
  • 25. add User “Robespierre”; add User “Rosseau”; ! “Rosseau” invites “Roberpierre”; “Robespierre" accept invite from “Rosseau" “Rosseau” create group “Vive la France!” with tag “Liberté, égalité, fraternité” “Robespierre" post in “Vive la France!”, message “Let's meet next 14th and kill the king!” ! “Roberpierre" list friends; “Rosseau" add message "People who know little are usually great talkers, while men who know much say little”; ! “Rosseau" add message “I am sorry to inform you all that our friend and compatriot Roberspierre was guillotined. This bloody revolution is changing out country at a very high price. ” Let’s do a Social Network System
  • 27. API'S ! ▫︎REST API - A set of URL’s (names) and Actions ▫︎Must be expressive ▫︎Limited - beyond crud, has only HTTP verbs ▫︎With a rich language is hard to draw an API that is as rich ▫︎Expose and API (it can be rest) for language processing
  • 28. USER EXPERIENCE - UX ! ▫︎Should be build in top of the language ▫︎We don’t care how modern and visual is the design, as long as it talks the domain language ▫︎E.g. SQL is a DSL on data query and manipulation - how many UI’s are built in top of that? ▫︎Will an editor with auto-complete and validation work?
  • 29. TESTING ! ▫︎Unit, integration, component and contract test the application (independent of the language) ▫︎Add tests for language processing - parsing and interpreting ▫︎Add tests for language processing feedback ▫︎Add tests for domain and service executing through DSL
  • 30. OVERALL ARCHITECTURE ! ▫︎UI Layer ▫︎Web Layer (REST) ▫︎Language Processing Layer ▫︎Domain/Services Layer ▫︎Infrastructure Layer UI Layer Web / Rest Layer Language Processing Domain Layer Infrastructure Layer From Martin Fowler’s DSL
  • 32. COMMUNICATION ! ▫︎The DSL is the language of communication of business ▫︎Devs, QA, BA, PO, Business Specialist, even Stakeholders ▫︎Ubiquitous Language ▫︎“Semantic Meetings” to understand and refine words of the language, and their meaning
  • 33. DOMAIN-DRIVEN DESIGN ! ▫︎Important to start the discussion about Domain meaning - Entities, Services, Aggregates, Value-Objects ▫︎Design and Domain are emergent - they are created/ refactored with the development of the application ▫︎Create the DSL ▫︎Create the Semantic Model - connected to the DSL ▫︎Semantic Model is different than the Domain Model - the first is a subset of the second.
  • 34. PROGRAMMING LEVEL The fun of building a language
  • 35. OVERALL OF LANGUAGE PROCESSING Lexical Analysis Parsing Semantic Analysis Text Tokens AST Abstract Syntax Tree Code Generation Semantic
 Model
  • 36. grammar IML; ! program : (functionDecl | stat | expr)+; functionDecl : type ID LP formalParams? RP block; formalParams : formalParam (COMMA formalParam)*; formalParam : type ID; type : (DOUBLEDECL | INTDECL | STRINGDECL); varDecl : type ID (EQUAL expr)? SEMICOLON ; block : LB stat* RB; assignment : expr EQUAL expr SEMICOLON; conditional : IF expr THEN stat (ELSE stat)?; returnstat : RETURN expr? SEMICOLON; stat : block | varDecl | conditional | returnstat | assignment | expr SEMICOLON ; expr : functionExpr // f() | arrayExpr // g[] | unaryOpExpr | expr binaryOp | idExpr | intExpr BNF GRAMMARS
  • 37. ANTLR
  • 41. “Because language does not mimic the world, you can do things with it that are impossible under the law of physics. You are a god in language. You can create. Destroy. Rearrange. Shove words around however you like. You can make up stories about things that never happened to people who never existed. You can push a camel through the eye of a needle. It’s easy if ‘camel' and ‘needle’ are words. In language, mortality does not tick relentlessly. You can conceive of yourself as alive forever. Or you can imagine yourself dead. And then alive again. You can live, die, live, die, live, die, live.” The First Word: The Search for the Origins of Language Christine Kenneally
  • 43.
  • 44.
  • 45.
  • 46. Understand the Power of Languages, Domain-Specific Languages, for your project, architecture and business
  • 47. Language-Driven Development Define a DSL that is going to represent the whole set of functionalities that your application communicates with the external world. Build this DSL in top of your high-level language, this second will implement the more broad domain logic of your application. Design your architecture, UX, ubiquitous language, meetings with business, testing, external APIs… in top of that DSL. This DSL is going to be the language your application speaks
  • 48. For questions or suggestions: ! Marcos Vinicius @bymarkone github.com/bymarkone THANK YOU