Arthur
Arthur copied to clipboard
Semantic language-agnostic source code schema
Arthur
Arthur is a semantic language-agnostic UAST (universal abstract syntax tree) schema generator which uses source code as input and outputs unilingual and omnilingual ontologies derived from those language(s). Arthur parses source code using Babelfish and constructs the observed schema for use in a Grakn knowledge graph.
Schemas
Omnilingual Schema
| Languages | Segments |
|---|---|
| Bash, C++, C#, Go, Java, JavaScript, PHP, Python, Ruby | Arthur_Omnilingual_Base_Structure.gql Arthur_Omnilingual_Semantic_Roles.gql |
Unilingual Schemas
Supported Concepts
Structural
Conditional
- If/ElseIf/Else
- Switch/SwitchCase
Exception
- Try/Catch/Finally
Loop
- ForLoop
- ForEachLoop
- WhileLoop
- DoWhileLoop
Operator
Logical
- AndOperator
- OrOperator
Misc
- TernaryOperator
Relational
- RelationalOperator
Compare
- IsEqualOperator/IsNotEqualOperator
- IsEqualTypeOperator/IsNotEqualTypeOperator
Define
- DeclareVariableOperator
- InitializeVariableOperator
Misc
- Child
- Function
- InternalRole
- Language
- Literal
- Multi
- Name
- Role
- Token
- Type
- Wildcard