Quick Start

Get InputLayer running and execute your first query in 5 minutes.

1. Install

# Clone the repository
git clone https://github.com/inputlayer/inputlayer.git
cd inputlayer

# Build (requires Rust 1.88+)
cargo build --release

2. Start the Server and Client

# Start the server
./target/release/inputlayer-server

# In another terminal, start the client
./target/release/inputlayer-client

You should see:

Connecting to server at http://127.0.0.1:8080...
Connected!

Server status: healthy
Authenticated as: admin
Current knowledge graph: default

3. Add Some Data

+person[("alice", 30), ("bob", 25), ("charlie", 35)]

Output:

Inserted 3 fact(s) into 'person'.

4. Query the Data

?person(Name, Age)

Output:

NameAge
"alice"30
"bob"25
"charlie"35

3 rows

5. Add a Filter

?person(Name, Age), Age > 28

Output:

NameAge
"alice"30
"charlie"35

2 rows

6. Create a Rule

+senior(Name) <- person(Name, Age), Age >= 30

Output:

Rule 'senior' registered.
?senior(X)

Output:

X
"alice"
"charlie"

2 rows

7. Use Aggregation

+average_age(avg<Age>) <- person(_, Age)

Output:

Rule 'average_age' registered.
?average_age(X)

Output:

X
30.0

1 rows

What's Next?

Common Commands

CommandDescription
.helpShow all commands
.relList all relations
.ruleList all rules
.quitExit the REPL