A systems programming language with native knowledge graphs
Fifth combines imperative programming with built-in RDF knowledge graphs and SPARQL queries, all compiled to .NET.
fifth
main(): int {
name: string = "Test";
age: int = 30;
active: bool = true;
s: Store = @<
@prefix ex: <http://example.org/> .
ex:graph1 {
ex:Person ex:name {{ name }};
ex:age {{ age }};
ex:active {{ active }} .
}
>;
return 0;
} Why Fifth?
A language designed from the ground up to make knowledge representation a natural part of programming.
Imperative Programming
Fifth uses a familiar imperative syntax with strong typing, making it easy to pick up if you know C#, TypeScript, or Java.
fifth
greet(name: string): string {
return "Hello, " + name;
} Native Knowledge Graphs
Build and query RDF knowledge graphs as first-class language constructs — no external libraries needed.
fifth
db : Store = local_store("./quadstore_data");
q: Query = ?<
PREFIX todo: <http://example.org/todo#>
SELECT (COUNT(*) AS ?count)
WHERE { ?s ?p ?o }
>;
result: Result = q <- db; .NET Integration
Fifth compiles to .NET IL, giving you full access to the .NET ecosystem, NuGet packages, and cross-platform deployment.
fifth
std.print(String.Format("Hello from {0}!", "Fifth on .NET 10!"));