Kind: Function
Source: atloria-monorepo/libs/parser-core/src/techdocs/example-grounding.ts
If the enrichment markdown's ### Usage Example section calls ungrounded methods on the
entity, drop that section (keeping description/diagram/instructions) and return the offending
method names. A single hallucinated call makes the whole example untrustworthy — better no
example than a lying one. Returns the possibly-rewritten content + what was dropped.
Signature
tsfunction sanitizeEnrichmentExample(content: string, entity: Pick<Entity, 'name'> & Record<string, any>): { content: string; dropped: string[] }
Parameters
| Name | Type |
|---|---|
content | string |
entity | Pick<Entity, 'name'> & Record<string, any> |
Returns: { content: string; dropped: string[] }
Was this page helpful?