MCPcopy Create free account
hub / github.com/Noumena-Network/code / isValidSessionFacets

Function isValidSessionFacets

src/commands/insights.ts:3190–3204  ·  view source on GitHub ↗
(obj: unknown)

Source from the content-addressed store, hash-verified

3188}
3189
3190function isValidSessionFacets(obj: unknown): obj is SessionFacets {
3191 if (!obj || typeof obj !== 'object') return false
3192 const o = obj as Record<string, unknown>
3193 return (
3194 typeof o.underlying_goal === 'string' &&
3195 typeof o.outcome === 'string' &&
3196 typeof o.brief_summary === 'string' &&
3197 o.goal_categories !== null &&
3198 typeof o.goal_categories === 'object' &&
3199 o.user_satisfaction_counts !== null &&
3200 typeof o.user_satisfaction_counts === 'object' &&
3201 o.friction_counts !== null &&
3202 typeof o.friction_counts === 'object'
3203 )
3204}
3205
3206export default usageReport

Callers 2

loadCachedFacetsFunction · 0.85
extractFacetsFromAPIFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected