Skip to content

Migrate sample to OGX (Open GenAI Stack) 1.2.5 - #24

Open
JslYoon wants to merge 2 commits into
redhat-developer:mainfrom
JslYoon:ogx-client-migration
Open

JslYoon wants to merge 2 commits into
redhat-developer:mainfrom
JslYoon:ogx-client-migration

Conversation

@JslYoon

@JslYoon JslYoon commented Oct 5, 2026 •

Copy link
Copy Markdown

Summary

Migrates this sample from Llama Stack to OGX (Open GenAI Stack) 1.2.5, the upstream rename of Llama Stack. Covers the Python app SDK, the server runtime config, the Backstage/RHDH software template, k8s resource names, and docs.

https://redhat.atlassian.net/browse/RHIDP-15863

https://redhat.atlassian.net/browse/RHIDP-17526

What changed

App SDK — llama-stack-client/llama-stack replaced with ogx-client==1.2.5:

  • OgxClient(base_url=...); list endpoints now return a response object with a .data list (vector_stores.list().data, vector_stores.files.list(...).data, models.list().data) instead of being directly iterable.
  • Create endpoints take request objects: vector_stores.create(OpenAICreateVectorStoreRequestWithExtraBody(name=...)), vector_stores.files.create(open_ai_attach_file_request=OpenAIAttachFileRequest(file_id=...)).
  • files.create(file=<str path>, purpose=...) takes a str path (preserves basename).
  • Type remaps aliased to old names to minimize churn (OpenAIResponseObject, OpenAIFileObject, OpenAIResponseOutputMessageFileSearchToolCallResults).
  • Added explicit openai>=2.14.0,<3 (previously a transitive dep of llama-stack-client; pinned <3 because v3 drifts the beta.chat.completions.parse surface the code uses).

Server + template + infra — rebranded to OGX:

  • Server deps/config under start-local-ogx/ (was start-local-llamastack/); run.yaml migrated to the OGX 1.2.5 API surface.
  • Template (ogx-agentic), secret ogx-secrets, k8s resources (${name}-ogx, service-ogx), runtime sidecar image agentic-ogx.
  • Docs updated.

Fixes bundled in:

  • Safety check runs via Llama Guard chat instead of /v1/moderations.
  • unknown classification routing renders a graceful prompt instead of an error.
  • Server starts with --insecure (no TLS certs required locally).

Kept intentionally: env var names LLAMA_STACK_URL / LLAMA_STACK_SERVER_OPENAI (their values point at the renamed -ogx service), config key llamastack:, check_llama_stack_availability, and ollama/llama-guard/.llama data dirs. Repo name unchanged.

Testing

  • 180 unit tests pass; ruff clean.
  • Note: unit tests are mocked and do not prove runtime correctness against a live OGX server — a live smoke test is still recommended before merge.

Note on images

Template appContainer/ogxContainer point at quay.io/redhat-ai-dev/*. redhat-ai-dev/agentic-ogx:latest is not published yet — upstream CI needs to build/publish it for deploys to pull the OGX runtime sidecar.

🤖 Generated with Claude Code

@JslYoon
JslYoon requested review from a team, gabemontero and maysunfaisal as code owners October 5, 2026 17:42
@JslYoon
JslYoon force-pushed the ogx-client-migration branch from 071669e to aa37b12 Compare October 5, 2026 17:45
Migrate this sample from Llama Stack to OGX (Open GenAI Stack) 1.2.5,
the upstream rename of Llama Stack. Covers the Python app SDK, the
server runtime config, the Backstage/RHDH software template, k8s
resource names, and docs.

App SDK: replace llama-stack-client/llama-stack with ogx-client==1.2.5.
List endpoints now return a response object with a .data list; create
endpoints take request objects; files.create takes a str path. Type
remaps are aliased to the old names to minimize churn. Add an explicit
openai>=2.14.0,<3 dependency (previously transitive) pinned below v3,
which drifts the beta.chat.completions.parse surface the code uses.

Server + template + infra: rebrand to OGX. Server deps/config move
under start-local-ogx/, run.yaml migrates to the OGX 1.2.5 API surface,
and k8s/template resources use the -ogx naming and agentic-ogx runtime
image. Docs updated.

Also bundled: safety check runs via Llama Guard chat instead of
/v1/moderations; unknown classification routing renders a graceful
prompt instead of an error; the server starts with --insecure.

Kept intentionally: env var names LLAMA_STACK_URL /
LLAMA_STACK_SERVER_OPENAI (values point at the renamed -ogx service),
config key llamastack:, check_llama_stack_availability, and the
ollama/llama-guard/.llama data dirs. Template images point at
quay.io/redhat-ai-dev/*.

180 unit tests pass; ruff clean. Unit tests are mocked and do not
prove runtime correctness against a live OGX server.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
@JslYoon
JslYoon force-pushed the ogx-client-migration branch from aa37b12 to 79cf306 Compare October 5, 2026 17:56
@gabemontero

Copy link
Copy Markdown
Contributor

use of a local ogx instance is not working (the instance does not come up) ... I've reported it to @JslYoon and he is working it

in the interim I'm pivoting to deploying on OCP and giving that a go

Signed-off-by: Lucas <lyoon@redhat.com>
@gabemontero

Copy link
Copy Markdown
Contributor

so @JslYoon the ogx deployment is failing when I launch the template because it tries to pull the image

quay.io/redhat-ai-dev/agentic-ogx:latest

which does not exist

looking at https://quay.io/organization/redhat-ai-dev there is an agentic-llama-stack:latest

IIRC @maysunfaisal did work to get the agentic-llama-stack image out there ... now, you probably want a newer image for OGX, so there is more involved than just retagging / renaming that image

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants