
Skill
tanstack-ai-memory-hindsight
wire TanStack AI hindsight memory adapter
Description
Use when wiring hindsight() from @tanstack/ai-memory/hindsight — a hosted memory adapter that buckets memory per conversation and exposes retain/recall/reflect tools to the model. Requires the optional @vectorize-io/hindsight-client peer.
SKILL.md
Hindsight Memory Adapter
Hosted recall/save adapter backed by Hindsight. Hindsight owns extraction and
ranking server-side, buckets memory into per-conversation "banks"
({tenantId|_}__{user}__{threadId}), and — uniquely — exposes LLM tools through recall so the
model can retain/recall/reflect directly.
Setup
import { memoryMiddleware } from '@tanstack/ai-memory'
import { hindsight } from '@tanstack/ai-memory/hindsight'
const memory = hindsight({ user: currentUserId }) // baseUrl defaults to HINDSIGHT_URL
memoryMiddleware({ adapter: memory, scope })
@vectorize-io/hindsight-client is an optional peer dependency, loaded lazily on
first use — install it where you use hindsight().
Options
user— durable user id for the bank key (falls back toscope.userId).baseUrl— Hindsight server URL (defaultHINDSIGHT_URLorhttp://localhost:8888).budget— recall budget:'low' | 'mid' | 'high'(default'mid').onToolRetain/onToolRecall— callbacks fired when the model uses the memory tools.
Scope fields: bank id is {tenantId|_}__{user}__{threadId}. namespace is ignored.
Tools
recall returns hindsight_retain, hindsight_recall, and hindsight_reflect in its
tools plus a toolGuidance block. memoryMiddleware merges them into the run so the
model can manage long-term memory itself.
More skills from the ai repository
View all 19 skillsai-code-mode
execute sandboxed TypeScript code with LLMs
Jul 16AI SDKCode ExecutionSandboxingTanStack +1ai-core
configure TanStack AI agent features
Jul 17AgentsAIMiddlewareai-core/adapter-configuration
configure AI provider adapters
Jul 16AI SDKConfigurationLLMTanStackai-core/ag-ui-protocol
implement TanStack AI streaming protocol
Jul 16API DevelopmentLLMTanStackai-core/chat-experience
implement chat experiences with TanStack AI
Jul 23API DevelopmentFrontendLLMTanStackai-core/custom-backend-integration
integrate custom backends with TanStack AI
Jul 17AIAPI DevelopmentBackendTanStack
More from TanStack
View publisheraggregation
perform data aggregation in TanStack Table
table
Jul 26Data AnalysisFrontendTanStackapi-not-found
diagnose TanStack Table API errors
table
Jul 26DebuggingFrontendTanStackcell-selection
select rectangular cell ranges in tables
table
Jul 26Data AnalysisTanStackUI Componentsclient-vs-server
manage TanStack Table data pipelines
table
Jul 26Data PipelineFrontendPerformanceTanStackcolumn-faceting
build faceted filter UIs
table
Jul 26Data VisualizationFrontendTanStackcolumn-filtering
implement column filtering in TanStack Table
table
Jul 26Data AnalysisFrontendTanStack