Skip to content

Add oracle-agent-memory demo: three-layer agent memory with Oracle AI Database 26ai#230

Open
allenheltondev wants to merge 1 commit into
oracle-devrel:mainfrom
allenheltondev:feat/agent-memory-app
Open

Add oracle-agent-memory demo: three-layer agent memory with Oracle AI Database 26ai#230
allenheltondev wants to merge 1 commit into
oracle-devrel:mainfrom
allenheltondev:feat/agent-memory-app

Conversation

@allenheltondev

Copy link
Copy Markdown

Summary

What: Introduces a new demo app that trains an AI agent to mimic a user's social media voice using episodic, semantic, and reflection memory stored in Oracle AI Database 26ai.
Why: Demonstrates an end-to-end pattern (vectors + JSON + relational) for persistent agent memory and showcases Oracle AI Database 26ai + OCI Generative AI integration.

Key Features

Three-layer memory: Episodic (vectorized posts), Semantic (style profile JSON), Reflection (periodic profile diffs).
End-to-end demo: Server (Node.js/TypeScript + oracledb), client (React + Vite), and DB schema + seed data included.
Cloud-ready provisioning: Optional Terraform to provision an Always Free Autonomous AI Database and emit a populated .env.

Setup & Quick Test

Terraform (Path A):
cd apps/oracle-agent-memory/terraform
cp terraform.tfvars.example terraform.tfvars
terraform init && terraform apply
terraform output -raw env_file > ../.env
cd .. && npm install && npm run schema && npm run seed && npm run dev

Existing DB (Path B):
cp .env.example .env → edit with Oracle + OCI credentials
npm install && npm run schema && npm run seed && npm run dev
Verify: Open http://localhost:5173, generate a draft, save a post, and confirm reflection triggers after 5 saves.

Notes & Considerations

Privacy: All queries filter on user_id. DELETE is soft by default.
Idempotence: npm run seed is idempotent (clears and reloads demo data).
Models: Defaults use OCI Generative AI model IDs (override with OCI_CHAT_MODEL_ID / OCI_EMBED_MODEL_ID).
PowerShell tip: Use UTF-8 write when capturing Terraform output on Windows (see README).

Testing / Review Checklist

Manual: Generate drafts, save posts, confirm style profile updates and reflections.
DB: Confirm schema.sql creates tables and HNSW index and that seed populates posts and style_profile.
Terraform: Optionally run the terraform flow to validate provisioning and generated .env.

Signed-off-by: Allen Helton <allenheltondev@gmail.com>
@oracle-contributor-agreement

Copy link
Copy Markdown

Thank you for your pull request and welcome to our community! To contribute, please sign the Oracle Contributor Agreement (OCA).
The following contributors of this PR have not signed the OCA:

To sign the OCA, please create an Oracle account and sign the OCA in Oracle's Contributor Agreement Application.

When signing the OCA, please provide your GitHub username. After signing the OCA and getting an OCA approval from Oracle, this PR will be automatically updated.

If you are an Oracle employee, please make sure that you are a member of the main Oracle GitHub organization, and your membership in this organization is public.

@oracle-contributor-agreement oracle-contributor-agreement Bot added the OCA Required At least one contributor does not have an approved Oracle Contributor Agreement. label Jul 15, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

OCA Required At least one contributor does not have an approved Oracle Contributor Agreement.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant