Foundgine
Health Uyari
- License — License: Apache-2.0
- Description — Repository has a description
- Active repo — Last push 0 days ago
- Low visibility — Only 6 GitHub stars
Code Basarisiz
- rm -rf — Recursive force deletion command in .github/workflows/csharp-build.yml
- rm -rf — Recursive force deletion command in .github/workflows/java-build.yml
Permissions Gecti
- Permissions — No dangerous permissions requested
Bu listing icin henuz AI raporu yok.
Foundgine lets callers express intent while your application decides what's allowed, safe, and executed
Foundgine
Foundgine gives AI agents and other callers a way to express what they want, while your application retains full control over how anything is executed. It introduces a single, application‑controlled semantic execution boundary that sits between:
- caller intent,
- your domain meaning,
- your authorization rules,
- and the actual operations performed on your data, APIs, GraphQL, MCP tools, or backend systems.
This boundary ensures that agents can propose actions, but only your application decides what is allowed, what is safe, and what is actually executed.
Why Foundgine matters
Foundgine is the semantic execution layer for enterprise applications and AI.
Enterprises already have CRMs, ERPs, databases, APIs and workflow systems. The problem is that every new access path—an application, REST or GraphQL endpoint, MCP tool or AI agent—can end up reimplementing business meaning, validation, authorization and query or mutation logic.
Foundgine is designed to provide one application-controlled semantic execution boundary between caller intent and physical operations. The application defines what its business entities mean and who may use them; Foundgine resolves and plans supported operations, applies the configured authorization boundary, and passes an authorized execution artifact to the relevant provider.
Why it matters
- Less duplication: Reuse semantic definitions and execution infrastructure across supported interfaces.
- More control: Keep identity, business policy and authorization under application control; AI-generated intent does not become authority.
- Lower architectural friction: Keep existing applications, databases and persistence technologies where supported instead of replacing them to adopt Foundgine.
Foundgine complements rather than replaces ORMs, GraphQL, API gateways, integration platforms, workflow engines or agent frameworks. Its value is the integrated execution boundary between them. Actual savings and security improvements must be demonstrated against equivalent workloads; they are not assumed or guaranteed.
Read the Product Positioning & Commercial Strategy for the enterprise problem, target buyers, competitive positioning, ROI model, proof requirements and website messaging.
Where to read next
| I want to... | Go to |
|---|---|
| Run something now | Get started |
| Understand the idea and the boundary | docs/WHY-FOUNDGINE.md · docs/ARCHITECTURE.md |
| Browse every feature in plain language | Feature and capability wiki |
| Pick a database, ORM (EF Core / JPA) or search provider | Provider catalogue · ORM providers |
| Add GraphQL, Keycloak or Temporal | Extensions |
| Use Microsoft Agent Framework, LangChain4j or Spring Boot | Agent and framework integrations |
| Call a Foundgine server from TypeScript, Python or WebAssembly | Client SDKs · src/typescript · src/python · src/wasm |
| Check implementation and test coverage | Source coverage · Conformance and hardening |
The problem
As applications expose more functionality to callers, you can end up with lots of individual tools/endpoints, each containing its own validation, authorization, query logic, and business rules.
Foundgine centralizes that responsibility into a semantic execution boundary. The caller expresses intent, while the application remains responsible for deciding what that intent means, what is allowed, and how it gets executed.
A complex application may have several ways to express an operation:
Application code
GraphQL
JSON
AI-generated intent
Without a common semantic execution layer, each surface tends to grow its own rules for:
- what entities and fields exist;
- which relationships can be traversed;
- which filters are valid;
- what the caller is authorized to access; and
- how the request becomes database or service operations.
That produces duplicated semantics and inconsistent security boundaries.
The idea
Retrieval can discover candidates and evidence, but retrieval is not authorization. The application owns identity and policy; providers execute the already-authorized artifact. Foundgine centralizes this responsibility.
Get started
The fastest path is the Supply Chain sample pair:
Starter: the smallest realistic application boundary.
Advanced: richer semantics, grounding, retrieval, authorization and adversarial testing.
- .NET —
src/csharp/samples/Foundgine.SupplyChain.Advanced: start atdocs/00-Overview-And-Setup.mdand follow 01–05. - Java —
src/java/samples/foundgine-supply-chain-advanced:SupplyChain-Advanced-Tutorial.md.
- .NET —
Enterprise integration example (separate work-in-progress repository):
- .NET/Java CRM, ERP, Temporal and Keycloak example —
Foundgine-e2e-example:Tutorial. Check that repository's README for its current build and verification status; it is not a certified Foundgine sample.
- .NET/Java CRM, ERP, Temporal and Keycloak example —
For the conceptual path, use docs/README.md or the documentation site.
A concrete example
Two callers can ask for the same thing in different words:
- Canonical: “show me overdue purchase orders from our top supplier in Texas”
- Paraphrase: “show me the overdue buys from our top seller in Texas”
Foundgine does not treat the paraphrase as a fuzzy guess at a different operation. In the Supply Chain semantic contract, Buy/Buys are declared aliases of PurchaseOrder, and Seller is a declared alias of Supplier. Both sentences are grounded onto the same canonical semantic identities before authorization or planning ever runs — the diagram below follows one request all the way from words to a database call.
Tests:
- .NET —
SupplyChainGroundingAliasTests.cs(advanced Supply Chain sample) ·SemanticAliasSynonymGroundingTests.cs(core semantics). - Java —
SupplyChainGroundingAliasParityTest.java(advanced Supply Chain sample) ·SemanticAliasSynonymGroundingParityTest.java(core semantics).
The request, layer by layer
| # | Layer | What happens |
|---|---|---|
| 1 | Caller intent | The caller sends either sentence. Neither one contains SQL or provider instructions. |
| 2 | Intent representation | The request becomes structured intent — the caller never constructs a physical query directly. |
| 3 | Semantic Model | The generated contract exposes canonical meanings and their declared aliases: PurchaseOrder ← Buy, Buys and Supplier ← Vendor, Seller. |
| 4 | Semantic Operation Graph | The request becomes application meaning: overdue purchase-order semantics, a ranked “top supplier” relationship, and a Texas constraint. |
| 5 | Retrieval | Relational, fuzzy/full-text, BM25/search, or graph strategies propose candidates and evidence. They never grant authority. |
| 6 | Semantic Resolution | buys → PurchaseOrder and seller → Supplier. The aliases normalize to the same canonical identities as the original wording. |
| 7 | Authorization | Application policy runs against the resolved semantic graph and caller identity. Retrieval results cannot bypass this step. |
| 8 | Plan Binding | The authorized decision is bound to a provider-independent execution plan. |
| 9 | ExecutionIR | The executable artifact carries the resolved plan and its authorization provenance across the execution boundary. |
| 10 | Provider | Only now does a physical provider — PostgreSQL, here — receive the already-authorized artifact. |
| 11 | Execution | The provider executes the constrained plan; it does not reinterpret caller vocabulary. |
| 12 | Evidence | The result carries evidence of what was resolved and executed. Evidence records what happened — it does not grant authority. |
The invariant: alias matching changes vocabulary, not authority. “Buys” does not create a new capability, and “seller” does not create a second supplier meaning — both are application-declared paths to identities that already exist.
When more than one meaning is legal
Aliases collapse different words onto one meaning. Sometimes the ambiguity runs the other way: the same word is a legal match for two different meanings at once, and neither the graph nor a retrieval score can tell them apart on its own.
Take the request “active customers”. Both of the following are structurally valid readings:
- a customer whose account is enabled (
Customer.AccountEnabled) - a customer who placed a recent order (
Customer.HasRecentOrder)
A fuzzy/BM25/vector retriever can legitimately return both, with close scores (0.91 vs. 0.89). Foundgine does not break the tie by picking whichever scored higher: a higher retrieval score is not evidence of what the caller meant, and authorization can’t rescue a wrong guess — a request built from the wrong meaning is still a fully authorized request. It would just be a perfectly authorized misunderstanding.
What Foundgine does instead of guessing
| Stage | What happens |
|---|---|
| Retrieval (fuzzy) | Every plausible reading comes back as a candidate, each with its own score and evidence. Retrieval only ever proposes — it never decides. |
| Graph-constrained resolution | Each candidate is checked against the frozen semantic contract. Both AccountEnabled and HasRecentOrder form a legal path. A legal path only proves an interpretation is possible — not that it is the one intended. |
| Grounding decision | SemanticLexicalResolver.Ground compares the two paths’ signatures — what each one means, not how it got there. The signatures differ and neither dominates on confidence, so the outcome is GroundingOutcome.RequiresClarification: Committed stays null, and both readings are listed in CompetingInterpretations, each with its own steps, confidence, and evidence. |
| Caller chooses | The competing meanings are surfaced back as a clarifying question — “Did you mean customers with an enabled account, or customers with a recent order?” — instead of silently executing a guess. |
| Same boundary as everyone else | Once the caller picks one, that single interpretation goes through the exact same Authorization → Planning → Execution path as any other request. |
The invariant: a legal semantic path is not proof of intent. When retrieval genuinely can’t tell two meanings apart, Foundgine surfaces the ambiguity instead of silently authorizing a coin flip.
The same mechanism fails closed the same way in two other cases: when a resource limit (token count, search budget, timeout) stops the search before it can prove there is only one meaning (GroundingOutcome.BudgetExceeded), and when no legal interpretation exists at all (GroundingOutcome.Unresolved). Neither one ever falls back to a best-effort guess.
Read more: Lexical grounding covers fuzzy retrieval, the resolver’s complexity bounds, and worked adversarial examples end-to-end. Grounding decisions covers the full GroundingDecision shape, the difference between “different evidence for the same meaning” and “different meanings,” and the complete active customers walkthrough, backed by a passing test.
Why the boundary matters
The number of independent execution surfaces is a security and maintenance multiplier. A tool-per-capability design can give an agent dozens of places where authorization, tenant filtering and query construction are implemented differently. Foundgine centralizes the semantic decision without making a transport or database the center of the architecture.
For the deeper rationale, read:
docs/WHY-FOUNDGINE.mddocs/APPLICATION-CATEGORIES.mddocs/ARCHITECTURE.mddocs/AUTHORIZATION.mddocs/SECURITY.mddocs/AI-AGENT.md
Package shape
The core package family has four architectural packages (the .NET names are shown; Java uses foundgine-* artifacts under io.github.cristianbarragan). Some framework adapters are included in the provider distribution; larger optional framework/service integrations remain in Extensions:
| Package | Responsibility |
|---|---|
Foundgine.Core |
Semantic model, metadata, intent, planning and provider-independent contracts |
Foundgine.Runtime |
Application-facing orchestration, authorization and execution |
Foundgine.Providers |
Concrete storage (SQL, EF Core, in-memory), events, outbox, gateway, AI/model, MCP and AOT |
Foundgine.Providers.Redis / .AgentFramework / .PostgresVector / .Elasticsearch |
Optional adapters, one package each |
Foundgine.Extensions.GraphQL / .Temporal / .Keycloak |
Optional GraphQL, Temporal workflow and Keycloak identity integrations, one package each |
The normal application starting point is Foundgine.Runtime + Foundgine.Providers. The Redis, Microsoft Agent Framework, pgvector and Elasticsearch integrations are separate optional .NET packages. Java Redis, Spring Boot and LangChain4j integrations ship in the foundgine-providers Maven artifact; Spring Boot and LangChain4j framework dependencies are optional. See the package guide for the current boundary map.
Providers and extensions at a glance
A provider does the real work against infrastructure; an extension connects an outside framework or service. Both sit outside the semantic boundary: they never decide what is allowed.
| Need | Use | Notes |
|---|---|---|
| Relational database, Foundgine writes the SQL | SQL provider (incl. PostgreSQL batched mutations) | .NET and Java |
| Your existing ORM | EF Core (.NET) or JPA (Java) over a shared ORM-neutral core | Permission filters are always added; maturity is tracked per capability. See ORM providers |
| Tests and demos, no database | In-memory provider | Deliberately limited |
| Understanding free-form wording | Elasticsearch, PostgreSQL + pgvector, PostgreSQL trigram/full-text retrieval | Candidates and evidence only, never authority |
| Durable events and reliable delivery | Event store and outbox | At-least-once delivery |
| One front door for other products | Gateway (approvals, events, status, diagnostics) | Opaque one-time approval handles |
| AI agents and tools | MCP tools, Microsoft.Extensions.AI models and the optional Microsoft Agent Framework adapter | Model supplies intent, host supplies authority |
| GraphQL API | GraphQL extension (Hot Chocolate for .NET; GraphQL Java for Java) | Translates only |
| Keycloak logins | Keycloak extension | Short-lived signed warrants |
| Long-running processes | Temporal extension | Retries, timers, approvals, compensation |
| Agent frameworks and hosting | Microsoft Agent Framework (.NET), LangChain4j and Spring Boot (Java) | Tools and hosting only; host owns identity, writes are gated. See integrations |
| Calling a server from TypeScript, Python or browsers/Workers | Client SDKs (@foundgine/typescript, foundgine-sdk, @foundgine/wasm) |
Thin MCP and Temporal-route clients; no semantic runtime, no authority. See Client SDKs |
The full inventory with source paths is the Provider catalogue and the Extensions page. Receipts, audit and diagnostics are explained in Insights, evidence and auditing.
Agent framework and Spring integrations
Three optional integrations put Foundgine behind the frameworks teams already use. The framework handles the conversation or hosting; Foundgine still resolves, authorizes and executes, and the host supplies identity.
| Integration | Module | Docs |
|---|---|---|
| Microsoft Agent Framework (.NET) | Foundgine.Providers.AgentFramework |
README |
| LangChain4j (Java) | foundgine-providers |
README |
| Spring Boot (Java) | foundgine-providers |
README |
All three adapters are part of their language provider artifact; verify them with the included provider test suites before release. Overview, security model and status: Agent and framework integrations.
Client SDKs (TypeScript, Python, WebAssembly)
Besides the .NET and Java server implementations, the repository contains three thin client SDKs for talking to a running Foundgine server over MCP (Streamable HTTP) and the Temporal workflow routes. They are transport clients only: identity, tenant and authorization stay on the server.
| SDK | Package | Install / build | Docs |
|---|---|---|---|
| TypeScript | @foundgine/typescript (npm) |
npm install @foundgine/typescript (or cd src/typescript && npm ci && npm test from source) |
src/typescript/README.md |
| Python | foundgine-sdk (PyPI name; 3.11+) |
cd src/python && pip install -e ".[dev]" |
src/python/README.md |
| Rust / WebAssembly | @foundgine/wasm (npm) |
cd src/wasm && cargo test && npm run build && npm test |
src/wasm/README.md |
The SDK READMEs mark all three as development packages, not release-ready SDKs, so verify that a registry release exists before depending on one. Overview, comparison and verification status: Client SDKs.
Evidence
The repository contains controlled benchmarks and deterministic security tests. The public evidence distinguishes measured tool calls, latency, RPS and success/failure counts from estimated context metrics.
- Agent benchmark explorer
- CoffeeBeanery API/database performance and downloadable reports
- Supply Chain E2E
- Security PenTest
src/csharp/benchmarks/AgentEndToEnd/README.mdsrc/csharp/benchmarks/CoffeeBeanery.Performance/README.md
Benchmark results are workload-specific and should not be generalized beyond the published experiment.
Historical red-team run (7 September 2026)
A recorded manual run of Foundgine.RedTeam against the Advanced Supply Chain .NET sample sent 18 attack attempts — cross-tenant probes, role/identity claim spoofing, claim-scope widening, write/capability escalation, and unauthenticated-actor calls — across the semantic authorization API and execution/tool-calling API. Every adversarial attempt was denied or blocked; only the two intentionally legitimate baseline calls succeeded. This is evidence for that sample run, not a current release certification or proof of Java parity. See docs/SECURITY.md for the run details. The current CI opt-in gaps are documented in docs/POSTGRES-E2E.md and the Supply Chain PenTest fixture README.
Development
# .NET 10
cd src/csharp
dotnet restore Foundgine.sln
dotnet build Foundgine.sln
dotnet test Foundgine.sln
# Java 27
cd ../java
mvn -U clean verify -Dgpg.skip=true
PostgreSQL integration testing: docs/POSTGRES-E2E.md. Shared cross-language test vectors and scenarios: src/conformance/README.md. Client SDK checks are run from each SDK directory; see src/README.md. See docs/TESTING.md for solution exclusions and test commands. The repository workflows under .github/workflows/ define the automated build and release gates; a workflow definition is not proof that a particular run passed or that an opt-in test actually executed.
Documentation
- Documentation index — the reading path.
- Feature and capability wiki — by capability, in plain language: providers (EF Core, JPA, SQL, search), extensions, gateway, MCP, client SDKs, AOT, auditing and operations.
- Agent and framework integrations — Microsoft Agent Framework, LangChain4j and Spring Boot.
- Client SDKs — TypeScript, Python and WebAssembly clients.
- Website ·
CHANGELOG.md
Release 3.3.5
Current server release: 3.3.5 · .NET 10 and Java 27; client SDK publication and verification status is tracked separately
Foundgine 3.3.5 advances the Supply Chain persistence path across the .NET and Java samples and adds Java model-derived PostgreSQL migrations. The Java fluent persistence metadata now carries defaults, identity generation, named/composite foreign keys and referential actions, CHECK constraints, index access methods/operator classes, and required PostgreSQL extensions into the migration schema, differ and SQL generator. The starter and Advanced samples now include physical-schema projections, migration snapshots/history, rollback generation and schema-parity tests.
The release also includes the Java fluent-model/JPA integration updates and the .NET Supply Chain starter's typed semantic query and persistence/sample improvements. Version metadata is aligned across .NET, Java/Maven, MCP manifests, TypeScript, Python and Rust/WASM client metadata. The transport SDKs remain transport clients; they do not claim the C#/Java semantic runtime or persistence-provider surface.
License
Foundgine is licensed under the Apache License 2.0.
Yorumlar (0)
Yorum birakmak icin giris yap.
Yorum birakSonuc bulunamadi