Working on a flame related “self improving” - Knowledge Database for PostgreSQL in all kind of code snippets in all languages C++, Python and whatever script else comes up. This WILL be useful for anyone starting coding scripts or plugins. I am wondering if that could be of interest at all to the community. I only have the older 2025.2.2 ready for tests. Ok, here my Idea:
For my Autodesk Flame examples, the important distinction is not just “store code” versus “store docs.” It is the retrieval contract.
You want the system to answer two very different intents:
- “Just answer my question quickly”
- “Give me the exact real material, not a paraphrase”
Those should not use the same retrieval mode, even if they use the same underlying Wisdom database.
I would classify stored code information by evidence level and by retrieval intent.
The key idea
Not all stored code knowledge is equally trustworthy.
For something like Flame 2025.2.2 Python API, I would separate:
- canonical source material
- extracted structured knowledge
- reusable examples
- derived summaries
- conversational recollections
Then your AI node can decide how “strict” to be.
A practical classification model
- Canonical references
This is the highest-trust layer:
- official API docs
- vendor examples
- version-specific release docs
- local mirrored manuals
- exact code snippets from trusted source files
This is what you want for “real information.”
For Flame, this would be the official Flame 2025.2.2 API examples, signatures, object names, callback names, and supported patterns.
This layer should be versioned and source-attributed.
- Verified internal examples
These are examples you used successfully:
- working snippets from your own projects
- tested scripts
- code adapted from official docs and confirmed in production
- internal wrappers around the API
This is often even more useful than docs because it reflects what actually worked in your environment.
- Structured symbol knowledge
This is not raw code, but extracted facts:
- class names
- method signatures
- argument patterns
- return types
- lifecycle requirements
- object relationships
- version applicability
This layer makes quick answers possible without dragging full documents every time.
- Pattern recipes
These are higher-level tasks:
- “create batch export”
- “hook into selection changes”
- “inspect current segment”
- “iterate clips”
- “open a dialog”
- “trigger render/export flow”
These are intent-oriented and often span several functions or classes.
- Derived summaries and conversation memory
This is the lowest-trust but fastest layer:
- prior explanations
- chat-derived summaries
- notes like “Flame APIs are tricky here”
- human-written memory blurbs
Useful for routing, but not enough for exact answers alone.
That gives you a trust ladder:
- canonical
- verified internal
- structured
- recipe
- summary/chat memory
Then the AI can answer differently depending on what you asked.
For “just a question” versus “exact info playout”
I would define response modes explicitly.
- Quick Answer mode
Use:
- structured symbol knowledge
- recipe layer
- summary layer
- maybe top canonical excerpt if confidence is low
Goal:
- answer fast
- keep context small
- avoid overloading the model
For example:
“Flame 2025.2.2 clip iteration is usually done through X object family; here is the typical entry point and a minimal example.”
- Grounded Answer mode
Use:
- structured knowledge
- verified examples
- short canonical excerpts
Goal:
- still concise
- but backed by source-grade material
This is good when the API is tricky and hallucination risk is higher.
- Exact Info Playout mode
Use:
- canonical source excerpt
- verified example snippet
- exact version tag
- source path / source title / internal archive ref
- minimal interpretation
Goal:
- reproduce the real source material
- avoid AI paraphrase unless requested
For example:
“Here are the stored Flame 2025.2.2 examples and exact method signatures we have for this API area.”
That is the mode you want for vendor APIs where subtle naming differences matter.
I would not rely on one generic semantic search for all of this.
I would add classification fields so retrieval can be filtered before ranking.
Useful classification fields
For each stored record, I would want things like:
content_type: doc, symbol, snippet, recipe, transcript, note
trust_level: canonical, verified, derived
language: python, js, ts, c++, mixed
product: Autodesk Flame
product_version: 2025.2.2
api_area: media panel, clip, timeline, batch, export, hooks, UI
source_origin: official-doc, internal-project, client-project, conversation, generated-summary
exactness_mode: exact, normalized, summarized
tested_status: untested, tested, production-proven
retrieval_cost: low, medium, high
supersedes or applies_from / applies_to
Then a query like:
“get me the Autodesk Flame Python API examples for Flame 2025.2.2”
could automatically prefer:
- product = Flame
- version = 2025.2.2
- language = python
- trust = canonical or verified
- content_type = snippet or doc
- exclude chat summaries unless nothing else exists
That is how you stop “search overwhelm” while still getting real answers.
I think the most important distinction is between identity and interpretation.
For tricky APIs, store both:
- identity records: exact snippet, exact signature, exact excerpt
- interpretation records: what it means, when to use it, caveats
If the AI only retrieves interpretation, it may be helpful but unsafe.
If it only retrieves identity, it may be precise but not usable.
You want both, but separately typed.
For example:
- Identity:
flame.PyClip.get_something(...) exact snippet from source/manual
- Interpretation:
“This only works in Flame 2025.2.2 when called from X context, not during Y callback.”
That separation is extremely valuable.
How I would route user intent
The node could infer or accept a retrieval mode from phrasing:
-
“What is…” or “How do I…”:
default to quick or grounded answer
-
“Show me the exact example”
-
“Give me the real API snippet”
-
“Do not summarize”
-
“Version-specific”
-
“Exact 2025.2.2 behavior”
switch to exact playout mode
You could even let nodes expose a small retrieval policy:
fast
grounded
exact
forensic
That would be much cleaner than one-size-fits-all Wisdom lookup.
For your Autodesk Flame example specifically
I would store Flame knowledge in at least four parallel shapes:
-
Official doc excerpts
Short exact excerpts from Flame docs, version-tagged.
-
Exact code examples
Complete Python snippets from docs or your verified archive.
-
Structured API entries
Symbol-level facts:
- class
- method
- params
- version
- caveats
- related examples
- Working internal scripts
Your own tested scripts, tagged by task and version.
Then “just a question” can search layer 3 first and maybe 4.
“Exact info playout” can pull 1 and 2 directly, and optionally 4 if you want practical examples.
My recommendation
If you want this to be reliable, I would define retrieval classes like this:
-
exact_reference
Official/vendor or exact archived text
-
verified_example
Known working code
-
symbol_fact
Structured API facts
-
task_recipe
Intent-based workflow examples
-
advisory_note
Derived explanation, caveats, conversation memory
Then define answer modes:
-
quick
Prefer symbol_fact + task_recipe
-
grounded
Prefer verified_example + symbol_fact + short exact_reference
-
exact
Prefer exact_reference + verified_example, minimal paraphrase
That would give any AI harness a sane way to answer both casual questions and strict “show me the real thing” requests without blasting the whole archive into every prompt.
The biggest mistake to avoid is storing all of this as undifferentiated “memory text.” Once that happens, your Flame query competes with random client conversations and casual summaries, and the exact API truth gets diluted.
If you want, the next step we can brainstorm is the actual taxonomy for code-memory record types for any AI harness, such as symbol, snippet, doc_excerpt, task_recipe, project_pattern, conversation_fact, and archive_blob.
Just let me know that this is part of what you looking for.
Cheers,
Xteve