The document discusses using a genetic algorithm to automatically compose SOA applications by evolving XSLT programs. It describes setting up an initial population of random XSLT documents, transforming source XML with each XSLT to get result XML, comparing result XML to target XML via XML diff to calculate fitness, selecting individuals for reproduction and crossover to create new offspring, and repeating over generations to evolve higher fitness XSLT programs. The goal is to evolve an XSLT that can transform source XML into target XML.
Speaking 'Development Language' (Or, how to get your hands dirty with technic...Julie Meloni
Slides from an internal workshop at George Washington University Library on 12 June 2012. The goal of this workshop was to increase the number of people who can “work” on technical issues in the library. Topics were grouped into three main parts: "Development Lifecycle & Where You Fit In", "Computer Programming Basics", and "Python in Particular".
Speaking 'Development Language' (Or, how to get your hands dirty with technic...Julie Meloni
Slides from an internal workshop at George Washington University Library on 12 June 2012. The goal of this workshop was to increase the number of people who can “work” on technical issues in the library. Topics were grouped into three main parts: "Development Lifecycle & Where You Fit In", "Computer Programming Basics", and "Python in Particular".
Effective Java, Third Edition - Keepin' it EffectiveC4Media
Video and slides synchronized, mp3 and slide download available at URL https://bit.ly/2uOURQH.
Joshua Bloch covers some highlights from the third edition of “Effective Java”, concentrating on streams and lambdas. The recently released edition of Effective Java contains one new chapter, fourteen new items, and numerous changes to existing items. Filmed at qconnewyork.com.
Joshua Bloch is the author of Effective Java and coauthor of Java Puzzlers and Java Concurrency in Practice. He was formerly the chief Java architect at Google, a distinguished engineer at Sun Microsystems. He led the design and implementation of numerous Java platform features, including the Java 5 language enhancements and the Java Collections Framework.
This has been presented in association with Robosepians for Java concepts. Basic concepts of Java including features, conditional statements, loop statements, arrays, string, primitive datatypes, essentials of Java including oops concepts, classes, objects, polymorphism, advance topics including packages, exception handling, multihtreading and network programming have been discussed.
C# is a great programming language for modern development. Like any language, however, there are parts of the language and BCL that can trip you up if you have invalid assumptions as to what is going on behind the scenes. This presentation discusses a few of these pitfalls and how to avoid them.
Introduction to JPA and Hibernate including examplesecosio GmbH
In this talk, held as part of the Web Engineering lecture series at Vienna University of Technology, we introduce the main concepts of Java Persistence API (JPA) and Hibernate.
The first part of the presentation introduces the main principles of JDBC and outlines the major drawbacks of JDBC-based implementations. We then further outline the fundamental principles behind the concept of object relation mapping (ORM) and finally introduce JPA and Hibernate.
The lecture is accompanied by practical examples, which are available on GitHub.
The GENETIC ALGORITHM is a model of machine learning which derives its behavior from a metaphor of the processes of EVOLUTION in nature. Genetic Algorithm (GA) is a search heuristic that mimics the process of natural selection. This heuristic (also sometimes called a metaheuristic) is routinely used to generate useful solutions to optimization and search problems.
Using Genetic algorithm for Network Intrusion DetectionSagar Uday Kumar
Using Genetic algorithm for Network Intrusion Detection : Genetic Algorithm IDS involves detecting the intrusion based on the log history, possible intrusions that are likely to occur. In Genetic Algorithm, each connection will be considered as a chromosome” which consists of many “genes” ( properties of the connection like : sourceIP, targetIP, port no., protocol …), One has to find the fitness value of each such chromosomes to detect intrusion.
Performance of genetic algorithm is flexible enough to make it applicable to a wide range of problems, such as the problem of placing N queens on N by N chessboard in order that no two queens can attack each other which is known as ‘n-Queens problem.
Lack of information about details of the problem made genetic algorithm confused in searching state space of the problem
Class GA. Genetic Algorithm,Genetic Algorithmraed albadri
Genetic Algorithms are good at taking large, potentially huge search spaces and navigating them, looking for optimal combinations of things, solutions you might not otherwise find in a lifetime
Genetic Algorithm
Genetic algorithm are an optimization technique used to solve nonlinear or non differentiable optimization problems.
They use concepts from evolutionary biology to search for a global minimum to an optimization problem.
Genetic algorithms work by starting with an initial generation of candidate solutions that are tested against the objective function. We then generate subsequent generation of point from the first generation through selection, crossover and mutation.
Lets take a look at the different technique selection crossover and mutation on an example of a binary problem where the variables in the optimization problem can either take on a value of zero or one.
Selection means to retain the best performing parents from one generation to the next
To selection those make it through to the next generation just because they performed well in the previous generation
Now because they performed well they might also be used for crossover and then cross over what we do is we select common similarities between the different parent variables and keep those the same to create children variables that will be in the next generation.
The last thing is what’s known as mutation where we take a parent and mutate certain variables to take on random values and we create a child based off of the mutation.
A mutation allow genetic algorithms to avoid falling into local minima and it really helps them explore the solution space well.
So lets see an example of how this might work on an optimization problem of two variables x and y and the three sets of contours that we have here are each different minima to the optimization problem.
Now the green minima and the red minima our local minima while the blue one actually happens to be a global minima.
The yellow dots on here are the initial points , are the first generation for my genetic algorithm.
So the first step that the genetic algorithm does is . it evaluates all these points and determines the fitness function value for each one of them.
The next thing that will do is it will select a few good solution as the parent two continue on to the next generation.
So these green points here did we will keep those for the next generation and will also use them to create the subsequent generation.
So for iteration 2 regenerate those new points through selection crossover and mutation and then we evaluate the new population
We then repeat this process of generating new generation until the algorithm converges.
Genetic algorithms can converges through a variety of convergence criteria.
A couple popular ones are a fixed number of generation so the genetic algorithm will just run until it hit a certain number of generations
Another one is it will converge when the best objective function or best fitness function value is no longer changing or its changing by a really small amount.
FORECASTING OF RENEWABLE ENERGY PRODUCTION BY USING GENETIC ALGORITHM (GA) FO...u772020
My topic of thesis is about constructing prediction model of wind energy and solar energy by artificial neural network with genetic algorithm.
Because the electricity price in Nordic area is determined in advance, it is beneficial to construct prediction model for renewable energy. With the mentioned prediction model, we can construct hybrid system (wind energy and solar energy) to produce hydrogen. Then the fuel cell can produce electricity and connect to the network by using the constructed prediction model. In our prediction model, the critical parameters like 10 minutes average wind speed and deviation for wind energy could be used as historical data to train to artificial neural network (ANN). We also hope to utilize genetic algorithm (GA) to speed up the ANN training and hybrid system scale design.
genetic algorithm based music recommender systemneha pevekar
The goal of a recommender
system is to generate meaningful recommendations to
a collection of users for items or products that might
interest them.
Many of the largest e-commerce websites are already
using recommender systems to help their customers
find products to purchase or download.
Declarative Multilingual Information Extraction with SystemTLaura Chiticariu
Information extraction (IE), the task of extracting structured information from unstructured or semi-structured data, is increasingly important to a wide array of enterprise applications, ranging from Business Intelligence to Data-as-a-Service.
In the first part of the talk, we give an overview of SystemT, a declarative IE system designed and developed to address the requirements driven by modern applications: scalability, expressivity, and transparency. SystemT is based on the basic principle underlying relational database technology: complete separation of specification from execution. SystemT uses a declarative language for expressing NLP algorithms called AQL, and an optimizer that generates high-performance algebraic execution plans for AQL rules. It makes IE orders of magnitude more scalable and easy to use, maintain and customize. Today, SystemT ships with multiple products across 4 IBM Software Brands and it being taught in universities. Our ongoing research and development efforts focus on making SystemT more usable for both technical and business users, and continuing enhancing its core functionalities based on natural language processing, machine learning, and database technology.
In the second part of the talk we present POLYGLOT, a multilingual semantic role labeling system capable of semantically parsing sentences in 9 different languages from 4 different language groups. The key feature of the system is that it treats the semantic labels of the English Proposition Bank as “universal semantic labels”: Given a sentence in any of the supported languages, POLYGLOT will predict appropriate English PropBank frame and role annotation. We illustrate how these universal semantic labels can be used within SystemT to create information extractors that immediately work across different languages. In addition, we illustrate how we automatically generate Proposition Banks for new languages in order to enable multilingual SRL and discuss some challenges of crosslingual semantics.
Effective Java, Third Edition - Keepin' it EffectiveC4Media
Video and slides synchronized, mp3 and slide download available at URL https://bit.ly/2uOURQH.
Joshua Bloch covers some highlights from the third edition of “Effective Java”, concentrating on streams and lambdas. The recently released edition of Effective Java contains one new chapter, fourteen new items, and numerous changes to existing items. Filmed at qconnewyork.com.
Joshua Bloch is the author of Effective Java and coauthor of Java Puzzlers and Java Concurrency in Practice. He was formerly the chief Java architect at Google, a distinguished engineer at Sun Microsystems. He led the design and implementation of numerous Java platform features, including the Java 5 language enhancements and the Java Collections Framework.
This has been presented in association with Robosepians for Java concepts. Basic concepts of Java including features, conditional statements, loop statements, arrays, string, primitive datatypes, essentials of Java including oops concepts, classes, objects, polymorphism, advance topics including packages, exception handling, multihtreading and network programming have been discussed.
C# is a great programming language for modern development. Like any language, however, there are parts of the language and BCL that can trip you up if you have invalid assumptions as to what is going on behind the scenes. This presentation discusses a few of these pitfalls and how to avoid them.
Introduction to JPA and Hibernate including examplesecosio GmbH
In this talk, held as part of the Web Engineering lecture series at Vienna University of Technology, we introduce the main concepts of Java Persistence API (JPA) and Hibernate.
The first part of the presentation introduces the main principles of JDBC and outlines the major drawbacks of JDBC-based implementations. We then further outline the fundamental principles behind the concept of object relation mapping (ORM) and finally introduce JPA and Hibernate.
The lecture is accompanied by practical examples, which are available on GitHub.
The GENETIC ALGORITHM is a model of machine learning which derives its behavior from a metaphor of the processes of EVOLUTION in nature. Genetic Algorithm (GA) is a search heuristic that mimics the process of natural selection. This heuristic (also sometimes called a metaheuristic) is routinely used to generate useful solutions to optimization and search problems.
Using Genetic algorithm for Network Intrusion DetectionSagar Uday Kumar
Using Genetic algorithm for Network Intrusion Detection : Genetic Algorithm IDS involves detecting the intrusion based on the log history, possible intrusions that are likely to occur. In Genetic Algorithm, each connection will be considered as a chromosome” which consists of many “genes” ( properties of the connection like : sourceIP, targetIP, port no., protocol …), One has to find the fitness value of each such chromosomes to detect intrusion.
Performance of genetic algorithm is flexible enough to make it applicable to a wide range of problems, such as the problem of placing N queens on N by N chessboard in order that no two queens can attack each other which is known as ‘n-Queens problem.
Lack of information about details of the problem made genetic algorithm confused in searching state space of the problem
Class GA. Genetic Algorithm,Genetic Algorithmraed albadri
Genetic Algorithms are good at taking large, potentially huge search spaces and navigating them, looking for optimal combinations of things, solutions you might not otherwise find in a lifetime
Genetic Algorithm
Genetic algorithm are an optimization technique used to solve nonlinear or non differentiable optimization problems.
They use concepts from evolutionary biology to search for a global minimum to an optimization problem.
Genetic algorithms work by starting with an initial generation of candidate solutions that are tested against the objective function. We then generate subsequent generation of point from the first generation through selection, crossover and mutation.
Lets take a look at the different technique selection crossover and mutation on an example of a binary problem where the variables in the optimization problem can either take on a value of zero or one.
Selection means to retain the best performing parents from one generation to the next
To selection those make it through to the next generation just because they performed well in the previous generation
Now because they performed well they might also be used for crossover and then cross over what we do is we select common similarities between the different parent variables and keep those the same to create children variables that will be in the next generation.
The last thing is what’s known as mutation where we take a parent and mutate certain variables to take on random values and we create a child based off of the mutation.
A mutation allow genetic algorithms to avoid falling into local minima and it really helps them explore the solution space well.
So lets see an example of how this might work on an optimization problem of two variables x and y and the three sets of contours that we have here are each different minima to the optimization problem.
Now the green minima and the red minima our local minima while the blue one actually happens to be a global minima.
The yellow dots on here are the initial points , are the first generation for my genetic algorithm.
So the first step that the genetic algorithm does is . it evaluates all these points and determines the fitness function value for each one of them.
The next thing that will do is it will select a few good solution as the parent two continue on to the next generation.
So these green points here did we will keep those for the next generation and will also use them to create the subsequent generation.
So for iteration 2 regenerate those new points through selection crossover and mutation and then we evaluate the new population
We then repeat this process of generating new generation until the algorithm converges.
Genetic algorithms can converges through a variety of convergence criteria.
A couple popular ones are a fixed number of generation so the genetic algorithm will just run until it hit a certain number of generations
Another one is it will converge when the best objective function or best fitness function value is no longer changing or its changing by a really small amount.
FORECASTING OF RENEWABLE ENERGY PRODUCTION BY USING GENETIC ALGORITHM (GA) FO...u772020
My topic of thesis is about constructing prediction model of wind energy and solar energy by artificial neural network with genetic algorithm.
Because the electricity price in Nordic area is determined in advance, it is beneficial to construct prediction model for renewable energy. With the mentioned prediction model, we can construct hybrid system (wind energy and solar energy) to produce hydrogen. Then the fuel cell can produce electricity and connect to the network by using the constructed prediction model. In our prediction model, the critical parameters like 10 minutes average wind speed and deviation for wind energy could be used as historical data to train to artificial neural network (ANN). We also hope to utilize genetic algorithm (GA) to speed up the ANN training and hybrid system scale design.
genetic algorithm based music recommender systemneha pevekar
The goal of a recommender
system is to generate meaningful recommendations to
a collection of users for items or products that might
interest them.
Many of the largest e-commerce websites are already
using recommender systems to help their customers
find products to purchase or download.
Declarative Multilingual Information Extraction with SystemTLaura Chiticariu
Information extraction (IE), the task of extracting structured information from unstructured or semi-structured data, is increasingly important to a wide array of enterprise applications, ranging from Business Intelligence to Data-as-a-Service.
In the first part of the talk, we give an overview of SystemT, a declarative IE system designed and developed to address the requirements driven by modern applications: scalability, expressivity, and transparency. SystemT is based on the basic principle underlying relational database technology: complete separation of specification from execution. SystemT uses a declarative language for expressing NLP algorithms called AQL, and an optimizer that generates high-performance algebraic execution plans for AQL rules. It makes IE orders of magnitude more scalable and easy to use, maintain and customize. Today, SystemT ships with multiple products across 4 IBM Software Brands and it being taught in universities. Our ongoing research and development efforts focus on making SystemT more usable for both technical and business users, and continuing enhancing its core functionalities based on natural language processing, machine learning, and database technology.
In the second part of the talk we present POLYGLOT, a multilingual semantic role labeling system capable of semantically parsing sentences in 9 different languages from 4 different language groups. The key feature of the system is that it treats the semantic labels of the English Proposition Bank as “universal semantic labels”: Given a sentence in any of the supported languages, POLYGLOT will predict appropriate English PropBank frame and role annotation. We illustrate how these universal semantic labels can be used within SystemT to create information extractors that immediately work across different languages. In addition, we illustrate how we automatically generate Proposition Banks for new languages in order to enable multilingual SRL and discuss some challenges of crosslingual semantics.
Miller Columns (used in iPhone and Mac Finder) are an elegant way of displaying and navigating a tree. This talk describes a JavaScript implementation of Miller Columns, and why JavaScript needs modules and a standard library.
When things can't be done in such a way that a small change to the db causes many changes and recompilation of your app is this really agile? Do you really believe it or had sworn to it? I use my own technique to minimize or completety eliminate this common problem. Come to see what you might never heard of.
Building nTier Applications with Entity Framework Services (Part 1)David McCarter
Learn how to build real world nTier applications with the new Entity Framework and related services. With this new technology built into .NET, you can easily wrap an object model around your database and have all the data access automatically generated or use your own stored procedures and views. The session will demonstrate how to create and consume these new technologies from the ground up and focus on database modeling including views and stored procedures along with coding against the model via LINQ. Dynamic data website will also be demonstrated. Lots of code! Make sure to attend Part 2.
Copy of the slides from the Advanced Web Development Workshop presented by Ed Bachta, Charlie Moad and Robert Stein of the Indianapolis Museum of Art during the Museums and the Web 2008 conference in Montreal
Similar to Implementing the Genetic Algorithm in XSLT: PoC (20)
Accelerate your Kubernetes clusters with Varnish CachingThijs Feryn
A presentation about the usage and availability of Varnish on Kubernetes. This talk explores the capabilities of Varnish caching and shows how to use the Varnish Helm chart to deploy it to Kubernetes.
This presentation was delivered at K8SUG Singapore. See https://feryn.eu/presentations/accelerate-your-kubernetes-clusters-with-varnish-caching-k8sug-singapore-28-2024 for more details.
Essentials of Automations: The Art of Triggers and Actions in FMESafe Software
In this second installment of our Essentials of Automations webinar series, we’ll explore the landscape of triggers and actions, guiding you through the nuances of authoring and adapting workspaces for seamless automations. Gain an understanding of the full spectrum of triggers and actions available in FME, empowering you to enhance your workspaces for efficient automation.
We’ll kick things off by showcasing the most commonly used event-based triggers, introducing you to various automation workflows like manual triggers, schedules, directory watchers, and more. Plus, see how these elements play out in real scenarios.
Whether you’re tweaking your current setup or building from the ground up, this session will arm you with the tools and insights needed to transform your FME usage into a powerhouse of productivity. Join us to discover effective strategies that simplify complex processes, enhancing your productivity and transforming your data management practices with FME. Let’s turn complexity into clarity and make your workspaces work wonders!
In his public lecture, Christian Timmerer provides insights into the fascinating history of video streaming, starting from its humble beginnings before YouTube to the groundbreaking technologies that now dominate platforms like Netflix and ORF ON. Timmerer also presents provocative contributions of his own that have significantly influenced the industry. He concludes by looking at future challenges and invites the audience to join in a discussion.
UiPath Test Automation using UiPath Test Suite series, part 4DianaGray10
Welcome to UiPath Test Automation using UiPath Test Suite series part 4. In this session, we will cover Test Manager overview along with SAP heatmap.
The UiPath Test Manager overview with SAP heatmap webinar offers a concise yet comprehensive exploration of the role of a Test Manager within SAP environments, coupled with the utilization of heatmaps for effective testing strategies.
Participants will gain insights into the responsibilities, challenges, and best practices associated with test management in SAP projects. Additionally, the webinar delves into the significance of heatmaps as a visual aid for identifying testing priorities, areas of risk, and resource allocation within SAP landscapes. Through this session, attendees can expect to enhance their understanding of test management principles while learning practical approaches to optimize testing processes in SAP environments using heatmap visualization techniques
What will you get from this session?
1. Insights into SAP testing best practices
2. Heatmap utilization for testing
3. Optimization of testing processes
4. Demo
Topics covered:
Execution from the test manager
Orchestrator execution result
Defect reporting
SAP heatmap example with demo
Speaker:
Deepak Rai, Automation Practice Lead, Boundaryless Group and UiPath MVP
Transcript: Selling digital books in 2024: Insights from industry leaders - T...BookNet Canada
The publishing industry has been selling digital audiobooks and ebooks for over a decade and has found its groove. What’s changed? What has stayed the same? Where do we go from here? Join a group of leading sales peers from across the industry for a conversation about the lessons learned since the popularization of digital books, best practices, digital book supply chain management, and more.
Link to video recording: https://bnctechforum.ca/sessions/selling-digital-books-in-2024-insights-from-industry-leaders/
Presented by BookNet Canada on May 28, 2024, with support from the Department of Canadian Heritage.
Generative AI Deep Dive: Advancing from Proof of Concept to ProductionAggregage
Join Maher Hanafi, VP of Engineering at Betterworks, in this new session where he'll share a practical framework to transform Gen AI prototypes into impactful products! He'll delve into the complexities of data collection and management, model selection and optimization, and ensuring security, scalability, and responsible use.
Elevating Tactical DDD Patterns Through Object CalisthenicsDorra BARTAGUIZ
After immersing yourself in the blue book and its red counterpart, attending DDD-focused conferences, and applying tactical patterns, you're left with a crucial question: How do I ensure my design is effective? Tactical patterns within Domain-Driven Design (DDD) serve as guiding principles for creating clear and manageable domain models. However, achieving success with these patterns requires additional guidance. Interestingly, we've observed that a set of constraints initially designed for training purposes remarkably aligns with effective pattern implementation, offering a more ‘mechanical’ approach. Let's explore together how Object Calisthenics can elevate the design of your tactical DDD patterns, offering concrete help for those venturing into DDD for the first time!
The Metaverse and AI: how can decision-makers harness the Metaverse for their...Jen Stirrup
The Metaverse is popularized in science fiction, and now it is becoming closer to being a part of our daily lives through the use of social media and shopping companies. How can businesses survive in a world where Artificial Intelligence is becoming the present as well as the future of technology, and how does the Metaverse fit into business strategy when futurist ideas are developing into reality at accelerated rates? How do we do this when our data isn't up to scratch? How can we move towards success with our data so we are set up for the Metaverse when it arrives?
How can you help your company evolve, adapt, and succeed using Artificial Intelligence and the Metaverse to stay ahead of the competition? What are the potential issues, complications, and benefits that these technologies could bring to us and our organizations? In this session, Jen Stirrup will explain how to start thinking about these technologies as an organisation.
Why You Should Replace Windows 11 with Nitrux Linux 3.5.0 for enhanced perfor...SOFTTECHHUB
The choice of an operating system plays a pivotal role in shaping our computing experience. For decades, Microsoft's Windows has dominated the market, offering a familiar and widely adopted platform for personal and professional use. However, as technological advancements continue to push the boundaries of innovation, alternative operating systems have emerged, challenging the status quo and offering users a fresh perspective on computing.
One such alternative that has garnered significant attention and acclaim is Nitrux Linux 3.5.0, a sleek, powerful, and user-friendly Linux distribution that promises to redefine the way we interact with our devices. With its focus on performance, security, and customization, Nitrux Linux presents a compelling case for those seeking to break free from the constraints of proprietary software and embrace the freedom and flexibility of open-source computing.
Smart TV Buyer Insights Survey 2024 by 91mobiles.pdf91mobiles
91mobiles recently conducted a Smart TV Buyer Insights Survey in which we asked over 3,000 respondents about the TV they own, aspects they look at on a new TV, and their TV buying preferences.
FIDO Alliance Osaka Seminar: Passkeys at Amazon.pdf
Implementing the Genetic Algorithm in XSLT: PoC
1. Proof of Concept: SOA Application Composition using the Genetic Algorithm Jim Fuller http://www.ruminate.co.uk http://www.slgchorus.com
2.
3.
4.
5. MVC type architectures are popular Client Tier Presentation Tier Business Tier Integration Tier Resource Tier Data Repository, XML Binding, Persistence Model View Controller External web services Internal web services
6. WS MVC with the Browser Controller EventHandler SOAPEventHandler Model The Model receives events from the Controller and updates itself sending Data which gets transformed by our view components. View -IE web service client side processing -XSLT templates -CSS -Global.xml -Global.xsl HTTP GET HTTP POST REQUEST Internal web services External web services HTTP RESPONSE Internet Explorer Client
7.
8.
9.
10.
11.
12.
13.
14.
15.
16.
17.
18.
19.
20.
21.
22. M=500, G=51 Parameters Same as raw fitness, approaching 0 is better fitness Standardized fitness One fitness case Fitness Cases Node count on xmldiff patch file difference between result xml and target xml Raw fitness Subset of xslt instructions Function Set <a/> <b/> <c/> <d/> Terminal Set Generate an xslt program that transforms source xml into result xml which is equivalent to target xml Objective
23.
24.
25.
26. Step 1: Evaluate Fitness XSLT generation xslt Source.xml result.xml Target.xml evaluate fitness transformation xml diff Each individual is ranked, by testing xslt program against a source xml
34. Step 3. Primary Genetic Operations Selected XSLT population New generation Reproduction Individual reproduced into new generation
35. Step 3. Primary Genetic Operations Selected XSLT population New generation Creates 2 offspring ‘ Mom’ ‘ Dad’ Crossover ( Recombination ) Select parents then crossover creates 2 offspring
36. Step 3. Primary Genetic Operations Crossover ( Recombination ) ‘ Dad XSLT’ ‘ Mom XSLT’ ‘ offspring xslt’ ‘ offspring xslt’ New generation Swap nodes between selected parent xslt
37.
38. Step 3. Secondary Genetic Operations mutation ‘ selected XSLT’ Pick a node and randomly mutate Completely new set of instructions ‘ offspring xslt’
41. Step 3. Secondary Genetic Operations encapsulation ‘ selected XSLT’ ‘ define new function’ Identify useful subtrees and encapsulate by defining new function ‘ XSLT’
42. Step 3. Secondary Genetic Operations decimation Identify very poor fitness individuals and remove from population <xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="1.0"> </xsl:stylesheet> <xsl:stylesheet/>
43.
44.
45.
46.
47.
48.
49.
50.
51.
52.
53.
54.
55.
56.
57.
58.
59.
60. M=1000, G=51 Parameters three fitness cases Fitness Cases Node count on xmldiff patch file difference between result xml and target xml Raw fitness Subset of xslt instructions + ws:invoke Function Set <a/>, <b/> ( 2 numbers ) Terminal Set Generate an xslt program that multiplies 2 numbers, converts to Celsius and returns number in Chinese Objective
61.
62.
63.
64.
65.
Editor's Notes
My day job is that of internet services manager of a medium sized UK company which builds proprietary solutions involving web service and xml technologies; My primary interests initially revolved around XSLT and xml technologies; started up EXSLT along with Dave Pawson and Jeni Tennison which now enjoys widespread adoption/implementation, have done quite a bit of technical reviewing and co-authoring for the now defunct WROX, and as with many authors I have now moved over to their benefactors, e.g. now writing a tome for APRESS provisionally titled Ant Gems which is due to go to print march next year I am a typical application developer, having refreshed my skill set as the times have changed.
This talk will outline a journey which actually started with a desire to answer XSLT list member questions to a personal rediscovery of the genetic algorithm. Over the years of answering peoples questions on the XSLT list, I noticed that most of the questions were simple mapping transformations…e.g. I have this source xml and what to transform it into target xml. If the user knew the source and target xml, what automated methods could be brought to bear ? I wont be talking about REST, not because I don’t think it important or that it can’t be considered as the valid I see both REST and SOAP based web services existing quite happily together. xml technologies and some
Specifications are being finalized to handle complex messaging: orchestration, coordination, and routing
Due to the lack of critically adopted WS orchestration, composition, coordination standards, many are finding the MVC architecture approach a good match Instead of exposing a large variety of web services, expose one controller web service, which places the importance into the message body, simple interactions, complex messages. List MVC examples
SOAP response could be styled by XSLT This technique lies between typical Web Services and REST
I personally use Systinet WASP server, it takes care of everything a developer would want to not deal with….especially security. The folks who made WASP have a deep heritage with CORBA Instantly solve some problems…stateful web services Anchor is usually used in negative connotations, e.g. boat anchor antipatterns. With many specifications still being worked out, having an anchor in a storm is useful
By integrating Amazon Web Services, Amazon.com Research Services for Microsoft Office System will provide Microsoft Office System users with convenient and seamless access to Amazon.com from within Microsoft productivity applications via the Research Task Pane. Users will be able to access Amazon.com information and make purchases without launching a browser or leaving their document, e-mail message or presentation. For example, a customer reading a bibliography in a Word document could easily click on a book title and purchase it from within the Research Task Pane without having to leave the Word document. Alternatively, a user will be able to add a footnote, bibliography entry and even cover art for books without needing to manually enter the information into a document. The Research Task Pane, a feature in the Microsoft Office 2003 Edition desktop applications (Word, Excel, the Outlook messaging and collaboration client, the PowerPoint presentation graphics program and Access) and in Microsoft Office System products OneNote (TM) note-taking program, Publisher and Visio drawing and diagramming software, uses industry-standard XML to enable users to retrieve and navigate relevant internal or external Web-based information, all from within Office programs. &quot;Amazon.com is breaking new ground in its use of XML-enabled Web Services that connect data from disparate systems, allow greater access to content, and create a more valuable experience for Web users,&quot; said Gytis Barzdukas, director of Office Product Management at Microsoft. &quot;By using the advancements of the Microsoft Office System, Microsoft and Amazon.com are transforming the desktop into a dynamic interface for Office customers everywhere.&quot; &quot;We are excited to help make this new service available to our customers,&quot; said Jeff Barr, Web services technical program manager at Amazon.com. &quot;This Microsoft Office System solution adds significant convenience for our Microsoft users and Amazon.com customers in finding and discovering products. We look forward to receiving feedback from users and to adding more features in the future.&quot;
Google (file:wsdl, file:wsil ) Look for inspection.wsil Refer to xmethods or well known UDDI registries The importance of a human understandable description of a web service should not be underestimated, What if the human description is in a different language ? Is the interface enough for automatic composition methods ?
With unlimited processing power and network bandwidth random search is fine. Intelligent software agents must have knowledge of the problem domain, either gained via learning ( neural network ) or through experts embedding knowledge As you will find out, GA does not need any specialist knowledge to solve a problem, and is quicker then random/linear search of large problem domains
This approach is not specific to any problem domain…can be applied to anything different partial effective gene combinations or “schemata” are searched in parallel manner Analogies are good in computing, but can be dangerous and can cloud over some of the more subtle aspects. It may so happen, what happens actually in nature is completely irrevelent, it just so happens that for some groups of problems this technique is potentially useful. Just because an analogy ‘feels right’ does not mean it explains ‘how’ something works…analogies are good for illustration purposes, not for explanation purposes.
where M(H, t) number of strings in population 't' with the schema 'H'. f(H) average fitness of the strings with the schema 'H'. F average fitness of the entire population. p1 probability of the schema being destroyed by crossover. p2 probability of the schema being destroyed by mutation. There are many variations
There are primary and secondary operations in the genetic operation
fitness is usually encompasses domain specific factors Primary operation: reproduction / recombination Secondary operation: mutation / editing / encapsulation
I was reviewing a book by WROX, called Beginning Databases….and since I was xml through and through I was forced to re-examine the differences between hierarchical data models with relational, etc… . Somehow this investigation led me to S BOX structures in LISP…..which re-introduced me to the genetic algorithm…and the idea of partial schemata being used to solve problems. The xslt guru David Carlisle probably didn’t know it, but him and his lot at XSLT UK caused me to investigate the fp approach using XSLT
LISP Symbolic expressions contain lists or atoms Use polish notation LISP is good at Programs and data have the same form A lisp program is its own parse tree EVAL function for lisp easy way to chain execution LISP facilitates the programming of hierarchical structures LISP is not a special GA language, in my opinion working with hierarchical computer programs is more expressive
Most programming languages internally convert to a parse tree, xml and especially xslt is akin to LISP in that we have direct access to the ‘tree’. Since XSLT is xml, we can easily manipulate computer programs as if it were data, this is important in the genetic operations. Since XSLT is the language for transforming XML, we could use it to transform XSLT programs. In practice there is a performance hit to this approach. In any event, this talk focuses on the strategy, and not the precise implementation method.
There will be reasons why I use ANT revealed later on, for one this was a natural choice as this talk is the final chapter in the previously mentioned book. Ant is a natural for dealing with lots of files, as we will be generating lots of xslt populations, applying transformations and various processes on them….was a no-brainer I have been using SAXON from the beginning, it is the only XSLT processor that implements XSLT 2.0.
This type of equivalency problem was chosen to make the prototype’s output easy to validate In addition, looking for logical equivalency, not worried about whitespace at the moment
* Comes from processing specific xslt individual with source.xml
500 xslt documents Going to generate 51 generations
Can supply with parameters to define nodedepth, repeats, supply a random seed, weight odds for certain elements or attributes to be generated. Uses a DTD to define allowable elements. As you can see the example template really does nothing useful, it is typical that starting populations consistently have a low fitness for its ultimate purpose
I wanted to reduce complexity in my early experiments so I avoided what I call early taxonomisation .
We indirectly measure the fitness of an XSLT program by checking its output with a desired target xml. Transformation to each xslt individual in the population Best Fitness for our purposes is defined as an exact match between result and target xml. Fitness does not have to be the result of a single metric, we could have multiple tests for a fitness of an individual Source and target xml were supplied as part of the problem formulation
Note that we have added a <root/> element, this is to ensure that XSLT that returned nothing, at least returned a valid xml document with one root node. There were situations where logically the fitness metric was not sufficient for certain special cases, in actuality having a number of source and target xml solved this issue.
IBM’s is based on some novel thinking, though I have not used it ( commercial ) Microsoft’s is fine and fast
Can choose the same individual for multiple operations, any number of times better fitness individuals have larger slice of the pie, so they will be selected more There can be some additional fitness penalties, for example in generation 0 many xslt files maybe invalid and not process at all.
Raw fitness is a metric in terms of the problem, for example if you are trying to optimise some business process that sells products. The number of products sold could be the fitness ranking ( more the better ). Fitness could be calculated over a series of values and event outcomes, e.g. we could have multiple source and target xmls and the overall ranking of an individual would be its ranking
From the selected population an individual is selected to be perfectly reproduced into the new generation
Normally creates 2 offspring, though in nature this is not the case.
Secondary operations tend to speed up convergence towards a solution, though if used too much will restrict convergence to ever occur.
Pick a point and randomly mutate Asexual In xslt this must run XML generator again to obtain nodeset to augment. a form of crossover
A random node is selected and its arguments are reorganized. Since ordering in xml is rarely important this operation has been omitted from our process Asexual
If any function has no side effects, and is not context dependent, has only constant atoms as arguments the editing operation will evaluate that function and replace it with a value. <xsl:if test=“true()”> <a></a> </xsl:if> <xsl:value select=“count(//a)”/> should always return the same amount if the source xml remains the same, so editing would resolve this and replace the xsl instruction with a 1.
Identify useful subtrees by searching high fitness individuals for common subtrees. The effect of encapsulation is that the selected subtree is no longer subject to the potentially disruptive effects of crossover.
Variety in a population drops quickly after generation 0, because GA focuses on marginally better fitness. To improve genetic diversity apply decimation, a set of rules which removes very poor fitness individuals. The example shows a 1 node XSLT, which is indeed very poor for solving our problem. An empty stylesheet is no use to us.
There are situations where convergence around a single version never occurs
Compiling xslt templates
Its hard to apply genetic operations to languages that do not have any discreteness, like xml has with angle brackets demarcating each instruction. This is why s-boxes and the functional approach was the AI choice, because it was easy to
* Comes from processing specific xslt individual with source.xml
Harvesting program is found at www.semantic-web.co.uk wsil solved UDDI/WSDL umbrella
SOAP 1.1 would have these HTTP headers: Content-Type: text/xml SOAPAction: &quot;http://example.com/ticker“ SOAP 1.2 message would have the following: Content-Type: application/soap+_xml; action=http://example.com/ticker Moving all of the metadata into the one place where it should be is also a good thing.
<inspection/> top level element defines namespaces used <service/> contains a service referencedNamespace, location of wsdl, UDDI specific stuff <description/> and <link/> may contain other elements, known as extensibility elements
Shows how we can use with both UDDI and WSDL Link element imports more wsil service definitions 2 conventions of usage; place inspection.wsil in root web directory of web server or under current dir of the webservice itself with the root level wsil containing links to these encapsulated wsil docs. avoid the 2nd convention of using a meta tag and use a RDDL doc to describe <HEAD> <META name=&quot;serviceInspection&quot; content=&quot;localservices.wsil&quot;> <META name=&quot;serviceInspection&quot; content=&quot;http://www.example.com/calculators.wsil&quot;> <META name=&quot;serviceInspection&quot; content=&quot;ftp://www.anotherexample.com/translators.wsil&quot;> </HEAD> xml schema exists
Notice extension mechanism Very easy to extend, any description or link element can have extension element
500 xslt documents Going to generate 51 generations
higher order orchestration standards are striving to become established supporting standards for SOA should stabilize by Q2 2004, with heavy commercial uptake for Q4 2004 XML, XSLT, and XPATH are successful XML schema, RELAX NG and DTD primary forms of schema languages UDDI is struggling to make an impact with developers There are some key differences though between SOA and CORBA/DCOM/RMI that developers and architects are getting confused with. We are possibly occupying that no mans land between white box reuse and true black box components
Does a car build itself based on a set of criteria ? Do we expect it ? Nano technology ……. Allowing problem domain experts to formulate problems assists in direct requirements capture Will a functional approach be the true path to black box reuse ? In a world of unlimited processing, who cares if a computer program is elegantly constructed ? In a world of unlimited bandwidth who cares if we use XML as the preferred over the wire format ? Successful programmatic methods are useful because they assist in modeling the problem. If that model is then used to generate a million line program…..focus on model-led development