Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,3 +1,9 @@
# Workspace: the engine stays the root package (path and crate name unchanged,
# per #82); the gateway is a separate member so HTTP/LLM client dependencies
# never enter the engine crate.
[workspace]
members = ["gateway"]

[package]
name = "inputlayer"
version = "0.1.0"
Expand Down
9 changes: 7 additions & 2 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -22,17 +22,22 @@ FROM rust:1.88-bookworm AS builder

WORKDIR /build

# Cache dependencies: copy manifest first, build a dummy lib to cache deps
# Cache dependencies: copy manifests first, build a dummy lib to cache deps.
# gateway/ is a workspace member, so its manifest and a stub source must
# exist for any cargo invocation to load the workspace.
COPY Cargo.toml ./
COPY gateway/Cargo.toml ./gateway/
RUN mkdir src && echo "fn main() {}" > src/main.rs && \
mkdir -p src/bin && echo "fn main() {}" > src/bin/server.rs && \
echo "" > src/lib.rs && \
mkdir -p gateway/src && echo "" > gateway/src/lib.rs && \
cargo generate-lockfile && \
cargo build --release --bin inputlayer-server 2>/dev/null || true && \
rm -rf src
rm -rf src gateway/src

# Build the real binary
COPY src/ src/
COPY gateway/ gateway/
COPY docs/ docs/
RUN cargo build --all-features --release --bin inputlayer-server && \
strip target/release/inputlayer-server
Expand Down
11 changes: 11 additions & 0 deletions gateway/Cargo.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
[package]
name = "inputlayer-gateway"
version = "0.1.0"
edition = "2021"
description = "InputLayer Gateway - the model gateway for Verified Completions (placeholder, see issue #83)"
license = "Elastic-2.0"
repository = "https://github.com/inputlayer/inputlayer"
rust-version = "1.88"
publish = false

[dependencies]
12 changes: 12 additions & 0 deletions gateway/src/lib.rs
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
//! InputLayer Gateway - placeholder workspace member.
//!
//! The gateway is the model gateway of the stack, the second deployable next to the engine: an
//! OpenAI-compatible endpoint (issue #83: `POST /v1/verify`, then #84: the
//! `/v1/chat/completions` proxy) that forwards completions to the model
//! provider and verifies every conversation against the loaded ontology,
//! attaching findings with quoted spans and proof trees.
//!
//! It lives as its own crate so HTTP and LLM client dependencies stay out of
//! the engine, and it talks to the engine over the public WebSocket API like
//! any other client. Production deployments run both: the IL engine and the
//! IL model gateway.
Loading