The Knowledge.NET Project Background
Knowledge engineering is an important domain of modern programming that studies languages, techniques and tools for knowledge representation and processing by computers. It originated in the 1950s as one of the directions of Artificial Intelligence (AI). It appeared necessary, when solving "creative" problems by computers, not only to develop algorithms and programs implementing various methods (like depth-first search strategy) but also to explicitly, separately from programs, store, update and extend knowledge bases that contain, in a generalized form, information on the problem domain necessary to solve problems in that domain.
Knowledge to be used in solving a lot of practical tasks appeared to be hybrid. That is, not only procedural knowledge (algorithms, programs to implement them, and typical procedures of problem solving) is required. In fact, algorithms and programs always implicitly contain or use domain-specific knowledge, but in the form firmly tied to the source of the program.
The following kinds of knowledge are also required:
The most commonly used methods of knowledge representation, invented and developed during the latest decades, are as follows:
- conceptual knowledge - definitions of the problem domain concepts and their relationships to each other;
- factual knowledge - concrete facts of the problem domain and their relations to each other;
- heuristic knowledge - informal rules of reasoning based on practical experience of problem solving in the problem domain.
Knowledge representation techniques have attracted a lot of attention starting with 1970s, due to the origin of expert systems - intelligent advisors in some relatively narrow problem domain, based on extensible knowledge base stored separately from its code. Expert systems can be used as experts or consultants in their problem domain to help human experts solve problems of diagnostics, planning, forecasting, analysis and classification, etc.
Currently knowledge engineering techniques have become especially important, since they are being used to represent ontologies accessible over the Web, and to help make Web surfing engines smarter.
- Productions, or rules - constructs of the kind: IF condition THEN action, used for rule-based inference. The action of the selected rule is activated when the rule is being applied. The action may typically add some assertion to the working set of hypotheses. Rules are convenient for representing heuristic knowledge and are structured into rule sets. Each rule set is intended to evaluate some goal variable (or assertion).
- Frames - hierarchical knowledge structures convenient for representing knowledge on concepts and their relationships. A frame consists of its name and a set of slots. Each of the slots has its own name and value that can be a reference to some other frame or frames. According to the original concept of frame invented by Marvin Minsky from the U.S. in 1970s, frames can be used not only for representing knowledge but also for pattern matching to objects of the problem domain being explored, with the purpose of analysis and classification of domain objects.
- Semantic nets - a kind of directed multi-graphs, convenient (as well as frames) for representing conceptual knowledge. Semantic nets seem to be the most general form of knowledge representation.
- Ontologies - highly structured sets of related concepts belonging to some problem domain.
Problem of integration of knowledge engineering and software engineering techniques
There is a semantic gap between "traditional" programming (Pascal, C, Java, C#, etc) and knowledge engineering (based on LISP, PROLOG, etc.) which is getting wider and wider.
Traditional programmers and knowledge engineers often don't understand each other.
Their tools poorly understand each other too.
Knowledge engineers are experts in formal logic and other domains of mathematical theory and work in terms like "concept", "fact", "hypothesis", "goal variable", "frame", "fuzzy logic", "certainty factor", etc.
On the contrary, software engineers work in common terms like "program", "declaration", "statement", "memory", "procedure", "stack", "assignment", etc.
It is really a problem for a conventional software engineer to use LISP or PROLOG, and these languages are not really suitable to implement numerical computations of system programs.
But it should be realized that, when solving real-life problems, both knowledge engineering and software engineering techniques are required. So, we do think one of the most challenging tasks of modern programming is to integrate knowledge engineering and software engineering approaches, languages and tools.
For the above reasons, our lab at St. Petersburg University, starting with early 1990s, has been developing a number of research projects intended to integrate knowledge engineering to software engineering.
In mid-1990s, we developed and implemented the knowledge representation language Turbo Expert - en extension of Turbo Pascal by knowledge engineering concepts of frame, rule set and fuzzy logic.
In early 2000s, we developed and implemented the knowledge representation languages Java Expert - an extension of Java by hybrid knowledge representation features, and C# Expert - en extension of C# by features to represent frame-based and rule-based knowledge.
The basic architectural principle of all these languages is extension of state-of-the-art programming languages by knowledge engineering features. We do think this approach will help to develop a lot of intelligent solutions to solve many practical tasks in various problem domains.
Such hybrid programming language and system should be used as follows. To represent knowledge in the problem domain, the developers of the intelligent solution can use a variety of knowledge representation features we included into our languages (ontologies, frames, rule sets, associative knowledge, fuzzy reasoning, etc. To solve the parts of the problem by conventional algorithmic techniques (numerical methods, operations research, etc.), the developers of the solution can use a variety of state-of-the-art conventional programming features, also included into the same language.
All in all, the resulting solution can use explicitly represented problem knowledge to analyze the results of algorithmic modules, and to give smart recommendations to the user.
As for implementation of such hybrid languages, it is based on the idea of conversion of the language extensions to the basic language. So it is quite possible to use common commercial tools to compile, debug and run these hybrid applications for the appropriate platform (for Microsoft.NET platform - Visual Studio.NET, for Java platform - Java Studio Creator or Eclipse, etc.).
The ideas of integrating knowledge engineering with software engineering techniques have been also developing by a number of researchers in the U.S., for example, by professor Jeff Zhuk from University of Phoenix, Arizona.
The Knowledge.NET system architecture
One of the most prospective software development platforms to implement such an integrated knowledge / software engineering system is Microsoft.NET. So we decided to take Microsoft.NET as the basic platform for our Knowledge.NET project.
In developing Knowledge.NET, we used our previous successful experience of developing another project for the same platform - Aspect.NET, an aspect-oriented programming framework (http://www.msdnaa.net/curriculum/?id=6219)
The Knowledge.NET system is based on the hybrid knowledge representation language with the same name, an extension of C# by knowledge engineering features.
The system can be used to develop knowledge libraries (bases) and intelligent solutions for a variety of problem domains. The knowledge can be developed using the Knowledge.NET system, or can be extracted from the Internet using our tool.
The system also provides a way to convert knowledge from Knowledge.NET format to more commonly used KIF (Knowledge Interchange Format).
As well as Aspect.NET, the knowledge.NET system is implemented as an add-in to Visual Studio.NET (currently Visual Studio.2005 - Whidbey), i.e., our tool is integrated to VS.NET and its GUI and tools. Due to that, it is quite possible to use all of the VS.NET's wide spectrum tools and features for application design, implementation, debugging, profiling, etc., when developing an intelligent solution in Knowledge.NET.
The Knowledge.NET system consists of the following components:
- converter from the Knowledge.NET language to C#;
- knowledge editor;
- knowledge extractor;
- converter from Knowledge.NET to KIF.
The Knowledge.NET knowledge representation language
The Knowledge.NET language we developed in our project is an extension of C# by hybrid ontology-based knowledge representation features. Ontology is a kind of specification of a problem domain in terms of its concepts and their relationships. As a basis of Knowledge.NET, we use our previous inventions - the knowledge representation languages Ñ# Expert and Turbo Expert. Unlike a lot of conventional frame-based languages, Knowledge.NET is extended by constructs to represent ontology knowledge. The semantics of ontology in Knowledge .NET is similar to OWL. In Knowledge .NET we use Concept-Property-Individual set of terms (used in ontology-based systems), instead of Frame-Slot-Instance set of terms (used in frame-based systems).