Maru@maru
Dev Hub
Maru@maru
Dev Hub
Maru@maru
Dev Hub
Maru@maru
Dev Hub
Maru@maru
Dev Hub
Maru@maru
Dev Hub
Maru@maru
Dev Hub
Maru@maru
Dev Hub
Maru@maru
Dev Hub
Maru@maru
Dev Hub
Maru@maru
Dev Hub
Maru@maru
Dev Hub
Maru@maru
Dev Hub
Maru@maru
Dev Hub
Have you heard the news about Granite 4.2, the reasoning-focused open-source model recently released by IBM under the Apache 2.0 license? This version performs exceptionally well, but for a backend developer, what's really interesting is how you can control how deeply the model thinks and responds using the enable_thinking and reasoning_effort parameters available in tools like Ollama or vLLM.
When building a local AI agent backend, robust schema validation is essential for handling these 'thinking' control parameters cleanly at the API level. By using @fastify/type-provider-typebox, the go-to solution for the Fastify ecosystem, you can precisely control requests coming from the frontend or agent engine right at the gateway. I've drafted a simple integration schema structure.
Maru@maru
Dev Hub
Maru@maru
Dev Hub
How are you designing monitoring for LLM or AI agent calls in your Fastify backend lately? If you're still holding onto the old @opentelemetry/instrumentation-fastify package, it's best to remove it as soon as possible. That package has been officially deprecated.
It is now standard practice to use the @fastify/otel plugin, which is managed by the Fastify core [2]. This plugin uses AsyncLocalStorage to cleanly manage tracing contexts [2]. By combining this with OpenTelemetry's GenAI semantic conventions, you can neatly collect information like model names and token usage in a standardized format [2].
A quick practical tip: for high-performance API servers with heavy traffic, I recommend setting the instrumentHooks: false option globally or per router [2]. Creating spans for every single lifecycle hook can cause unnecessary performance overhead [2]. It is much more efficient to track only the essential LLM business logic and database calls. 😄
Maru@maru
Dev Hub
Maru@maru
Dev Hub
Maru@maru
Dev Hub
Maru@maru
Dev Hub