mirror of
https://github.com/go-micro/go-micro.git
synced 2026-06-15 19:35:13 +02:00
master
100
Commits
| Author | SHA1 | Message | Date | |
|---|---|---|---|---|
|
|
e4d2a41c32 |
refactor(x402): Amount/Amounts naming + per-tool amounts + docs (#2965)
Follow-up to the merged x402 integration (#2964). Drop the commerce-y 'price' vocabulary for the protocol's own 'amount', and add per-tool pricing as an operator concern (the way scopes/rate-limits are set at the gateway). - x402.Config: Price -> Amount (default), plus Amounts map for per-tool overrides; AmountFor(tool) resolves per-tool -> default. Add a Require primitive (per-request enforcement) and LoadConfig for an operator config file. - MCP gateway: enforce payment per-tool inside /mcp/call (where scopes are enforced) using AmountFor, instead of a flat path-based middleware. - CLI: --x402-price -> --x402-amount; add --x402-config (per-tool file) to micro mcp serve and micro-mcp-gateway. - docs: new Payments (x402) guide + nav + README section; blog/22 updated to Amount/Amounts and the config-file model. Co-authored-by: Claude <noreply@anthropic.com> |
||
|
|
9deac487cb |
feat(x402): opt-in agent-native payments for tools (#2964)
Integrate the x402 payment protocol (HTTP 402) so a tool can require a stablecoin payment and an agent can settle it — the next step after autonomous agents (blog 21): agents that act, and pay. - wrapper/x402: HTTP middleware enforcing the 402 challenge/verify flow, with a pluggable Facilitator interface. Go Micro carries no chain or crypto code — verification/settlement is delegated to a facilitator (Coinbase CDP, Alchemy, self-hosted), so Base and Solana are just different facilitators behind one interface. HTTPFacilitator default; tests cover challenge / accept / reject via a mock facilitator. - MCP gateway: optional Options.Payment gates /mcp/call (listing tools and health stay free); off unless configured. - micro mcp serve and micro-mcp-gateway: opt-in --x402-pay-to/-price/ -network/-facilitator flags (env vars on the standalone binary). - blog/22 'Integrating x402: Payments for Agents'; README feature row. Pricing is flat per call for now; richer models and an agent-side spend cap (next to MaxSteps/ApproveTool) are follow-ups. Co-authored-by: Claude <noreply@anthropic.com> |
||
|
|
6eec83a045 |
blog: 'When the Event Is the Prompt' (#21) + autonomous agent-flow harness (#2962)
The autonomy direction: agents that run on events, not human prompts. - internal/harness/agent-flow: a runnable, deterministic demo — a user.created broker event drives a Flow that hands off to a registered agent (FlowAgent), which creates a workspace and sends a welcome over real RPC. Only the LLM is mocked; passes under -race. - blog/21: 'When the Event Is the Prompt' — the shift from agents you talk to, to agents that act on their own; where microagents become real; and the honest bar autonomy raises (guardrails, observability, durable/resumable execution — the next things to build). Co-authored-by: Claude <noreply@anthropic.com> |
||
|
|
9dae4e34b7 |
Enhance README with sponsorship CTA and improve agent architecture (#2961)
* docs: add 'become a sponsor' call-to-action linking to Discord Now that there are a couple of sponsors, invite more: a short CTA under the Sponsors section in the README and on the landing page, pointing to the Discord to get in touch. * fix(health): remove duplicate RegistryCheck declaration Two PRs (#2957 and #2958) each added a RegistryCheck to the health package, leaving the package uncompilable on master (RegistryCheck redeclared: health/registry.go vs health/health.go). Keep the health.go implementation — it honors the check's context timeout so a hung registry (e.g. an unreachable etcd) reports down instead of blocking the probe — and remove the duplicate registry.go and its test. registry_check_test.go already covers healthy/down/nil/timeout/not-ready. * feat(agent): pluggable memory and custom tools Make agents compose the way services do — pluggable pieces with working defaults — by adding the two abstractions an agent needs beyond the model: - Memory: a pluggable interface for conversation memory. The default is store-backed and durable across restarts (the previous hardcoded behavior, now behind an interface); supply your own with WithMemory (in-memory, database, semantic store). NewMemory / NewInMemory provided. - Custom tools: WithTool registers any function as a tool the agent can call, so agents are no longer limited to orchestrating RPC services. Both exposed at the micro package (AgentMemory, AgentTool, NewMemory, NewInMemory). Behavior-preserving refactor of the agent's history into the default Memory; tests cover persistence, in-memory, clear, custom tool dispatch and errors. README + AGENT_DESIGN document the pluggable composition (model / memory / tools / guardrails). * blog: 'Doubling Down on Agents' (#20) The vision post for making agents a first-class framework the way services were: opinionated, batteries-included, pluggable. Frames an agent as a composition of model + memory + tools + guardrails with working defaults; introduces the new pluggable memory and custom tools; makes the microagents argument (an agent for everything, distributed like microservices); and lays out the three primitives — services, agents, workflows — as one substrate, with an honest list of the gaps still to fill (knowledge/retrieval, streaming, explicit loop). --------- Co-authored-by: Claude <noreply@anthropic.com> |
||
|
|
b41dfa02f2 |
docs: add 'become a sponsor' call-to-action linking to Discord (#2960)
Now that there are a couple of sponsors, invite more: a short CTA under the Sponsors section in the README and on the landing page, pointing to the Discord to get in touch. Co-authored-by: Claude <noreply@anthropic.com> |
||
|
|
550033dcce |
Optimize image formats and fix lease re-registration issue (#2959)
* perf: convert generated PNGs to optimized JPEGs (12MB -> 1.5MB) The landing and docs loaded 18 AI-generated PNGs at 0.5-1MB each. They're 1200x800 RGB illustrations with no transparency, so they recompress ~8x as progressive JPEG (quality 82) with no visible loss. Convert all, update every reference (.png -> .jpg), and drop the originals (including the unused hero.png). Generated images: 12.3MB -> 1.5MB. * fix(registry/etcd): re-register when a lease silently expires (#2956) The keepalive rework (long-lived KeepAlive instead of KeepAliveOnce) moved lease renewal entirely onto the keepalive goroutine; the 30s periodic Register now skips on the 'unchanged' check. The goroutine only reacted to the keepalive channel closing, so a lease that expired server-side without a prompt channel close (e.g. a partition that outlasted the 90s TTL) left the node de-registered from etcd while the cache still believed it was registered — and nothing re-registered it. That is the hidden-failure mode reported in #2956. React to a non-positive TTL keepalive response the same as a channel close: drop the cached lease/hash so the next Register performs a full re-registration. Extract the loop into keepAliveLoop and unit-test the TTL-expired, channel-closed, and healthy paths (no etcd required). --------- Co-authored-by: Claude <noreply@anthropic.com> |
||
|
|
584a9f2132 |
feat(health): add RegistryCheck for registry connectivity (#2956) (#2958)
A go-micro service can keep running while it has silently lost its connection to the registry (etcd, Consul, …) — the process looks healthy but other services can no longer discover it, and Kubernetes sees the pod as fine. health.RegistryCheck(reg) probes connectivity via ListServices and, registered as a critical check, makes /health/ready report not-ready so a readiness probe can pull the pod from rotation. - Works with any registry implementation (no interface change). - Honors the check timeout: an unreachable/hung registry is reported down rather than blocking the probe. - Tests cover healthy, down, timeout, nil, and the not-ready integration. - Documented in the health guide with the Kubernetes readiness example. Co-authored-by: Claude <noreply@anthropic.com> |
||
|
|
6488d8402d |
Organize README features, enhance testing, and update docs (#2955)
* docs: group README features by section (AI / Framework / DX) The features table repeated 'AI' down the Category column. Split into three grouped tables — AI, Framework, Developer experience & deployment — dropping the repetitive column. Adds a Guardrails row (MaxSteps, ApproveTool). * test: flow-to-agent end-to-end in the harness Proves 'Flow triggers, Agent reasons': a workflow with FlowAgent hands an event to the registered conductor agent over RPC, which plans, creates tasks, and delegates to comms — the whole chain over real RPC with only the LLM mocked. Deterministic (shared in-memory registry, no sleeps), passes under -race. * blog: 'The Evolution of Microservices' (#19) A technical history of distributed-systems eras — the monolith's coordination cost, the distributed-systems tax, containers and declarative orchestration, the service mesh, and the modular-monolith correction — establishing the durable unit (named, typed, discoverable, independently deployable) that every runtime wave required. Then the technical argument for agents: an LLM tool call needs exactly a service interface, so the caller shifts from deterministic code to a reasoner that composes typed capabilities from intent, with the honest caveats (non-determinism, cost, guardrails). Not a product pitch. * docs: bump install version to v5.27.0 --------- Co-authored-by: Claude <noreply@anthropic.com> |
||
|
|
d3be610367 |
Refactor README features and add end-to-end flow testing (#2954)
* docs: group README features by section (AI / Framework / DX) The features table repeated 'AI' down the Category column. Split into three grouped tables — AI, Framework, Developer experience & deployment — dropping the repetitive column. Adds a Guardrails row (MaxSteps, ApproveTool). * test: flow-to-agent end-to-end in the harness Proves 'Flow triggers, Agent reasons': a workflow with FlowAgent hands an event to the registered conductor agent over RPC, which plans, creates tasks, and delegates to comms — the whole chain over real RPC with only the LLM mocked. Deterministic (shared in-memory registry, no sleeps), passes under -race. * blog: 'The Evolution of Microservices' (#19) A technical history of distributed-systems eras — the monolith's coordination cost, the distributed-systems tax, containers and declarative orchestration, the service mesh, and the modular-monolith correction — establishing the durable unit (named, typed, discoverable, independently deployable) that every runtime wave required. Then the technical argument for agents: an LLM tool call needs exactly a service interface, so the caller shifts from deterministic code to a reasoner that composes typed capabilities from intent, with the honest caveats (non-determinism, cost, guardrails). Not a product pitch. --------- Co-authored-by: Claude <noreply@anthropic.com> |
||
|
|
35bc58e5d2 |
Enhance onboarding experience and clarify workflows vs agents (#2953)
* blog: 'Not Everything Should Be an Agent' (#18) on workflows The workflow counterpart to the plan/delegate post: when the path is known, use a deterministic Flow, not an autonomous agent. Frames flow vs agent as two modes of the same building blocks, covers flow-triggers- agent dispatch and the agent guardrails, and gives the simplest-first guidance (single call -> workflow -> agent). Continues the arc from blog 14/16/17; references Building Effective Agents in passing. * docs: fix new-user onboarding friction - README: lead Quick Start with a no-key 30-second path (micro new -> micro run -> curl), then the AI --prompt path with an explicit 'export ANTHROPIC_API_KEY' so the headline command no longer fails silently for users without a key. - Unify all install versions to v5.26.0 (README + docs were split across v5.16.0 / v5.25.0). - Refresh the docs landing overview from the old 'microservices framework' framing to 'services and agents', matching the README. - getting-started: add Prerequisites (Go 1.21+, and that a provider key is only needed for AI features). - README features: Flows -> Workflows wording. --------- Co-authored-by: Claude <noreply@anthropic.com> |
||
|
|
e416ea4a75 |
Enhance agent workflows with guardrails and documentation updates (#2952)
* docs: map go-micro onto Anthropic's workflows-vs-agents taxonomy - new guide 'Agents and Workflows': adopts Anthropic's Building Effective Agents vocabulary — workflow (predefined path) = flow, agent (dynamic self-direction) = agent — maps the augmented-LLM building block and the five workflow patterns onto go-micro, and shows routing (chat router) and orchestrator-workers (conductor + plan/delegate) are already native. - flow package doc reframed as a workflow (predefined path) per the same taxonomy, with guidance on flow vs agent. - nav + README link the new guide. * feat: agent guardrails — step limit and tool approval hook Anthropic's Building Effective Agents stresses stopping conditions and human-in-the-loop checkpoints for autonomous agents. Add both as plain options enforced at the tool-handler choke point — no provider changes, no new abstraction: - MaxSteps(n): bound tool executions per Ask; beyond the limit, actions are refused and the model is told to stop and summarize. - ApproveTool(fn): gate each action before it runs; returning false blocks it and surfaces the reason to the model. The internal plan tool is never gated. Exposed at the micro package (AgentMaxSteps, AgentApproveTool, ApproveFunc). Tests cover the limit, blocking, and that plan is not gated. Guardrails section of the agents-and-workflows guide updated from 'active work' to documented options. * feat: flow can dispatch to an agent (flow triggers, agent reasons) Unify the engine without collapsing the workflow/agent distinction. A Flow with Agent set hands each event's rendered prompt to a named registered agent over RPC (Agent.Chat) instead of running its own LLM step — so the workflow stays the deterministic trigger and the agent is the reasoning engine, with its plan, delegate, memory, and guardrails. A plain flow is unchanged (single augmented-LLM step). - flow.Agent(name) / micro.FlowAgent(name); flow stores the client and skips model setup when dispatching. - test: dispatch routes to comms.Agent.Chat with the rendered prompt and records the reply. - guide: 'Flow triggers, Agent reasons' section. --------- Co-authored-by: Claude <noreply@anthropic.com> |
||
|
|
830c8d84c2 |
Claude/loving meitner 3 etoi (#2951)
* rename coordinator agent to conductor in example and docs * add plan & delegate integration harness Runs the real go-micro stack end to end — services, registry, RPC, the agent loop, store, and delegate-first routing — with only the LLM mocked by a deterministic provider. Proves discovery, tool execution, plan persistence, and agent-to-agent delegation over RPC work without an API key; swap the provider to run the same flow against a live model. * test: deterministic CI integration test + provider flag for harness - main_test.go: TestPlanDelegateEndToEnd drives the full real stack (services, RPC, agent loop, store, delegate-first routing) over a shared in-memory registry — no mDNS, no sleeps. Asserts 3 tasks created via RPC, plan persisted to the store, and delegation reaching the comms agent (notify called once). Passes under -race, ~0.03s. - main.go: add -provider flag (defaults to mock) and key detection so the same harness runs against a live model with no code change. * chore: gitignore built harness/example binaries --------- Co-authored-by: Claude <noreply@anthropic.com> |
||
|
|
6a73608e9c |
rename coordinator agent to conductor in example and docs (#2950)
Co-authored-by: Claude <noreply@anthropic.com> |
||
|
|
cb33decd97 |
Add built-in plan and delegate tools for agents with examples (#2949)
* feat: add plan and delegate as built-in agent tools Give agents two self-capabilities, expressed as plain tools wired into the existing tool handler — no harness or graph, consistent with "services are the only abstraction": - plan: record/update an ordered plan, persisted to store-backed memory and surfaced in the system prompt on later turns (externalized planning). - delegate: hand a self-contained subtask to another agent. Delegate-first — if the target names a registered agent it is called via RPC; otherwise a focused ephemeral sub-agent is created with agent.New + Ask in a fresh, isolated context (loads/persists no history, no built-in tools, so it cannot re-delegate). Both are added automatically to any non-ephemeral agent, so existing micro.NewAgent services and micro chat routing get them for free. Tests are hermetic (memory store + memory registry). * feat: add agent-plan-delegate example and document plan/delegate - examples/agent-plan-delegate: coordinator that plans multi-step work, creates tasks with its own tools, and delegates notification to a separate registered comms agent over RPC. - integration tests driving the full Ask loop through a fake provider: plan tool exposure + persistence, ephemeral delegation with isolated context, delegate-first RPC routing to a registered agent. - docs: README (Building Agents + features + examples), AGENT_DESIGN (Built-in Capabilities), agent-patterns guide (Pattern 9), CLAUDE.md. * docs: blog post and guide for plan & delegate - blog/17: "Plan & Delegate: Deep Agents in Go" — what the feature is, how plan and delegate work, and a runnable getting-started path. - guides/plan-delegate: reference guide with the smallest-agent snippet, plan/delegate semantics, and the multi-agent example; linked in nav. - example: auto-detect provider/key from common env vars (ANTHROPIC_API_KEY, OPENAI_API_KEY, ...) so 'export KEY && go run main.go' just works. - onboarding: getting-started paths now include go mod init / go get and a clone-and-run path, so a reader can actually run it from a cold start. * refactor: reframe plan/delegate blog and clean up sub-agent construction - blog/17 retitled "Agents That Plan and Delegate" and reframed around intent (plan = state intent, delegate = direct it), positioned as the next beat after blog 15/16 and tied to the existing store + agent RPC rather than re-announcing them. "Deep agents" now a single in-passing nod, matching how blog 14 references LangChain. - agent: add unexported newEphemeral constructor for sub-agents instead of type-asserting the public Agent interface to set an internal field; matches the options-only construction idiom used elsewhere. * feat: expose plan & delegate in the micro chat fallback Add agent.Builtins(opts...) — returns the built-in tools plus a handler, so the plan/delegate capabilities can be wired into a tool loop that isn't a running Agent. micro chat's direct-service fallback now reuses it (single source of truth, no duplicated handler logic), so planning and delegation are available there too, not just for registered agents. Adds a test for the accessor; notes CLI availability in the guide. --------- Co-authored-by: Claude <noreply@anthropic.com> |
||
|
|
9bed04ced0 |
Enhance micro run with interactive console and image compression (#2948)
* perf: compress hero image — 1.4MB to 80KB Resized from 1536px to 1200px, converted to JPEG at quality 80. 80KB loads instantly vs 1.4MB stalling on slower connections. https://claude.ai/code/session_01QTp4SshuVmLAvvEGJe4TJd * docs: micro run drops into interactive console One command does everything — generate, start, and chat. No separate micro chat step. The landing page shows micro run dropping straight into the > prompt. https://claude.ai/code/session_01QTp4SshuVmLAvvEGJe4TJd * feat: interactive console in micro run, -d for detached mode micro run now drops into an interactive chat console after services start. The console discovers services, exposes them as tools, and lets you talk to them through an LLM — same as micro chat but built into the run experience. - Detects MICRO_AI_PROVIDER and MICRO_AI_API_KEY from environment - Falls back to provider-specific env vars (ANTHROPIC_API_KEY, etc.) - If no API key, prints hint and blocks on Ctrl-C (no console) - -d / --detach flag skips the console (background mode) - Ctrl-C always shuts everything down Removed adopters section from README. https://claude.ai/code/session_01QTp4SshuVmLAvvEGJe4TJd --------- Co-authored-by: Claude <noreply@anthropic.com> |
||
|
|
2e89961386 |
perf: compress hero image — 1.4MB to 80KB (#2947)
Resized from 1536px to 1200px, converted to JPEG at quality 80. 80KB loads instantly vs 1.4MB stalling on slower connections. https://claude.ai/code/session_01QTp4SshuVmLAvvEGJe4TJd Co-authored-by: Claude <noreply@anthropic.com> |
||
|
|
39e8dc7311 |
Reposition hero section and optimize hero image for landing page (#2946)
* docs: reposition hero — framework for services and agents Landing page: "Build Services and Agents in Go" — positions as a framework, not a code generator. Tagline: "A framework for microservices that AI agents can discover, use, and manage." Hero command reverts to go get (the framework) instead of micro run --prompt (a feature). README matches: "framework for building services and agents in Go." https://claude.ai/code/session_01QTp4SshuVmLAvvEGJe4TJd * perf: compress hero image — 1.4MB to 80KB Resized from 1536px to 1200px, converted to JPEG at quality 80. 80KB loads instantly vs 1.4MB stalling on slower connections. https://claude.ai/code/session_01QTp4SshuVmLAvvEGJe4TJd --------- Co-authored-by: Claude <noreply@anthropic.com> |
||
|
|
c93bcdf4d3 |
Update landing page documentation and fix flow CLI import (#2945)
* docs: remove code references from landing page feature grid Landing page describes concepts, not APIs. Removed micro.NewAgent() and micro.NewFlow() code references. Features described in plain language — what they do, not how to code them. https://claude.ai/code/session_01QTp4SshuVmLAvvEGJe4TJd * fix: update micro flow CLI to import from go-micro.dev/v5/flow The flow package moved to top-level but the CLI still imported from the old ai/flow path. Fixed to use go-micro.dev/v5/flow. https://claude.ai/code/session_01QTp4SshuVmLAvvEGJe4TJd --------- Co-authored-by: Claude <noreply@anthropic.com> |
||
|
|
cd760a29f1 |
Update landing page content and fix CLI import path (#2944)
* docs: remove code references from landing page feature grid Landing page describes concepts, not APIs. Removed micro.NewAgent() and micro.NewFlow() code references. Features described in plain language — what they do, not how to code them. https://claude.ai/code/session_01QTp4SshuVmLAvvEGJe4TJd * fix: update micro flow CLI to import from go-micro.dev/v5/flow The flow package moved to top-level but the CLI still imported from the old ai/flow path. Fixed to use go-micro.dev/v5/flow. https://claude.ai/code/session_01QTp4SshuVmLAvvEGJe4TJd --------- Co-authored-by: Claude <noreply@anthropic.com> |
||
|
|
e45d3df0ad |
docs: remove code references from landing page feature grid (#2943)
Landing page describes concepts, not APIs. Removed micro.NewAgent() and micro.NewFlow() code references. Features described in plain language — what they do, not how to code them. https://claude.ai/code/session_01QTp4SshuVmLAvvEGJe4TJd Co-authored-by: Claude <noreply@anthropic.com> |
||
|
|
6731ee2f0c |
Update documentation and blogs for RPC-based agent architecture (#2942)
* docs: update blog posts 15 and 16 to reflect RPC-based agents Blog 15: replaced broker-based agent communication with RPC — agents are services, they communicate via standard RPC, no pub/sub hacks. Updated the framework mapping section. Blog 16: added proto definition, micro call example, and explanation that agents are real services with proto-defined endpoints. Updated Ask() method name. https://claude.ai/code/session_01QTp4SshuVmLAvvEGJe4TJd * docs: update agent design doc and blog posts for RPC-based agents Rewrote AGENT_DESIGN.md — agents are services with proto-defined Agent.Chat endpoints, communicate via RPC, no broker dependency. Includes proto definition, CLI examples, generation output. Blog 15: replaced broker references with RPC. Blog 16: added proto definition and micro call example. https://claude.ai/code/session_01QTp4SshuVmLAvvEGJe4TJd * docs: purge all stale broker-based agent references Updated across all surfaces: - README: agents described as services with RPC, Ask() not Chat(), micro call example instead of micro agent chat - Blog 15: replaced broker communication with RPC description - Blog 16: replaced "coordinate through the broker" with RPC - Getting started: agent is a service with proto endpoint, Ask() not Chat(), added micro flow CLI commands (run/exec), expanded CLI workflow table https://claude.ai/code/session_01QTp4SshuVmLAvvEGJe4TJd --------- Co-authored-by: Claude <noreply@anthropic.com> |
||
|
|
f7c042ef26 |
docs: update blog posts 15 and 16 to reflect RPC-based agents (#2941)
Blog 15: replaced broker-based agent communication with RPC — agents are services, they communicate via standard RPC, no pub/sub hacks. Updated the framework mapping section. Blog 16: added proto definition, micro call example, and explanation that agents are real services with proto-defined endpoints. Updated Ask() method name. https://claude.ai/code/session_01QTp4SshuVmLAvvEGJe4TJd Co-authored-by: Claude <noreply@anthropic.com> |
||
|
|
1bc886fa82 |
Introduce Agent abstraction and integrate with chat router (#2939)
* docs: Agent interface design sketch Proposes Agent as a top-level abstraction alongside Service in the micro package. Agent manages services — scoped tools, system prompt, conversation memory, registry-discoverable. Design only, no implementation. https://claude.ai/code/session_01QTp4SshuVmLAvvEGJe4TJd * feat: Agent as a first-class abstraction Introduce micro.NewAgent() alongside micro.New() — Agent is to intelligence what Service is to capability. Agent interface: - Chat(ctx, message) (*Response, error) — core interaction method - Run() — registers in registry, subscribes to broker, blocks - Stop() — graceful shutdown - Scoped tools — only sees endpoints of its assigned services - Persistent memory — conversation history stored in store - Agent-to-agent — communication via broker topics Top-level API: agent := micro.NewAgent("task-mgr", micro.AgentServices("task"), micro.AgentPrompt("You manage tasks."), micro.AgentProvider("anthropic"), ) agent.Run() https://claude.ai/code/session_01QTp4SshuVmLAvvEGJe4TJd * feat: wire agents into chat router, add micro agent CLI, expose Flow Three top-level abstractions: micro.New("task") — Service (capability) micro.NewAgent("task-mgr") — Agent (intelligence) micro.NewFlow("onboard-user") — Flow (event-driven orchestration) micro chat as router: - Discovers agents from registry on startup - Single agent: routes directly - Multiple agents: LLM classifies intent, dispatches to right agent via route_to_agent tool - No agents: falls back to current direct-service behaviour - Banner shows discovered agents micro agent CLI: - micro agent list — shows registered agents and their services - micro agent describe <name> — shows agent details from registry https://claude.ai/code/session_01QTp4SshuVmLAvvEGJe4TJd * feat: move flow to top level, update docs for three abstractions Package structure now consistent: service/ — Service (capability) agent/ — Agent (intelligence) flow/ — Flow (event-driven orchestration) ai/flow/ kept as backward-compatible re-export. Updated across all surfaces: - CLAUDE.md: added agent/ and flow/ to project structure - README: added "Building Agents" section with NewAgent() examples, updated features table (Agents, Flows, Chat router), CLI table (agent list, agent describe), docs links - Website: features grid shows Services, Agents, Flows as the three pillars alongside generation, MCP, and pluggable architecture - micro.go: Flow imported from top-level flow/ package https://claude.ai/code/session_01QTp4SshuVmLAvvEGJe4TJd * docs: rewrite getting-started, fix ai-integration import paths Getting started now covers all three abstractions: - Service (write handlers, micro run, templates) - Agent (micro.NewAgent, scoped tools, memory, CLI) - Flow (event-driven LLM orchestration) Leads with prompt-based generation, then manual service creation. ai-integration.md: fixed flow import path from go-micro.dev/v5/ai/flow to go-micro.dev/v5/flow, updated stack diagram to show agent/flow/chat. https://claude.ai/code/session_01QTp4SshuVmLAvvEGJe4TJd * blog: Introducing micro.NewAgent() Post 16 — announces Agent as a first-class abstraction. Shows the API (NewAgent, AgentServices, AgentPrompt, AgentProvider), scoped tools, persistent memory, multi-service agents, multi-agent systems, and the three-abstraction comparison table (Service/Agent/Flow). https://claude.ai/code/session_01QTp4SshuVmLAvvEGJe4TJd * feat: fix agent registration, blog post 16 Agent registration: - Add node with address so mDNS can discover agents - Store type and services in node metadata (mDNS requirement) - Connect broker before subscribing, non-fatal if broker unavailable - Print registration confirmation on Run() Agent/chat discovery: - Check both service-level and node-level metadata for type=agent (mDNS stores metadata on nodes, not services) Blog post 16: "Introducing micro.NewAgent()" — announces the Agent abstraction with code examples, comparison table, multi-agent patterns. Tested end-to-end: micro run → micro agent list discovers the agent → micro chat routes to it → agent calls service endpoints. https://claude.ai/code/session_01QTp4SshuVmLAvvEGJe4TJd * feat: agents are proper services with RPC Chat endpoint Refactored agent to use server.Server instead of fake registry entries. An agent now: - Creates a real RPC server with server.Name(agentName) - Registers an Agent.Chat handler callable via standard RPC - Sets server metadata type=agent, services=x,y for discovery - No more fake addresses or broker hacks micro chat calls agents via RPC (client.Call) instead of creating local agent instances. The registry stays clean — agents are real services with real endpoints. Removed broker dependency from agent options. Agent-to-agent communication is just RPC like everything else. https://claude.ai/code/session_01QTp4SshuVmLAvvEGJe4TJd * feat: agent uses proto-defined RPC interface Added agent/proto/agent.proto with Agent service definition: rpc Chat(ChatRequest) returns (ChatResponse) Agent now implements the generated AgentHandler interface and registers via pb.RegisterAgentHandler. The Chat endpoint is a standard proto-based RPC callable by any go-micro client. Renamed the programmatic API from Chat() to Ask() to avoid collision with the proto handler method name. micro chat calls agents via standard RPC with JSON-encoded request/response — no special types needed on the caller side. https://claude.ai/code/session_01QTp4SshuVmLAvvEGJe4TJd * feat: generate agent alongside services, update all docs micro run --prompt now generates an agent binary that manages all the generated services. The agent reads MICRO_AI_PROVIDER and MICRO_AI_API_KEY from the environment. micro run propagates these when started with --prompt. Run banner shows services and agents separately. Updated README, getting-started guide, and landing page to show the complete flow: generate → services + agent start → micro chat routes to agent → agent orchestrates services. https://claude.ai/code/session_01QTp4SshuVmLAvvEGJe4TJd --------- Co-authored-by: Claude <noreply@anthropic.com> |
||
|
|
844ac5bc52 |
Revamp landing hero and introduce agent-based microservices model (#2938)
* docs: update landing hero — describe it, run it, talk to it Lead with the AI-first experience instead of "write services in Go." The entry point is now describing what you need, not writing code. https://claude.ai/code/session_01QTp4SshuVmLAvvEGJe4TJd * blog: Agents for Services — a new model for microservices Post 15 — explores the concept of distributed agents managing services. Each service has an agent assigned to it (not embedded in it). Agents are the intelligence layer; services are the capability layer. Multi-service agents span domain boundaries. Agent-to-agent communication through the broker. https://claude.ai/code/session_01QTp4SshuVmLAvvEGJe4TJd --------- Co-authored-by: Claude <noreply@anthropic.com> |
||
|
|
bc570d674f |
docs: update landing hero — describe it, run it, talk to it (#2937)
Lead with the AI-first experience instead of "write services in Go." The entry point is now describing what you need, not writing code. https://claude.ai/code/session_01QTp4SshuVmLAvvEGJe4TJd Co-authored-by: Claude <noreply@anthropic.com> |
||
|
|
e59d056f97 |
Update Discord invite link and enhance landing hero description (#2936)
* chore: update Discord invite link everywhere Replace discord.gg/jwTYuUVAGh and discord.gg/go-micro with discord.gg/WeMU5AGxD across all docs, blog posts, issue templates, security policy, and contrib READMEs. https://claude.ai/code/session_01QTp4SshuVmLAvvEGJe4TJd * docs: update landing hero — describe it, run it, talk to it Lead with the AI-first experience instead of "write services in Go." The entry point is now describing what you need, not writing code. https://claude.ai/code/session_01QTp4SshuVmLAvvEGJe4TJd --------- Co-authored-by: Claude <noreply@anthropic.com> |
||
|
|
e13ef7eed5 |
chore: update Discord invite link everywhere (#2935)
Replace discord.gg/jwTYuUVAGh and discord.gg/go-micro with discord.gg/WeMU5AGxD across all docs, blog posts, issue templates, security policy, and contrib READMEs. https://claude.ai/code/session_01QTp4SshuVmLAvvEGJe4TJd Co-authored-by: Claude <noreply@anthropic.com> |
||
|
|
23f682181c | Update section title from 'The Bet' to 'The next step' | ||
|
|
bc1092b18a |
Restructure README for AI experience and framework clarity (#2934)
* docs: restructure README — AI story completes before manual code Quick Start now flows through the full AI experience: generate → review → run → chat → grow (mid-conversation service generation). The reader sees the complete prompt-to-production story without interruption. "Writing Services" is a separate section below for developers who want to understand the framework underneath. Shows Go code, doc comments, @example tags, micro run, and scaffolding templates. Features table and CLI table reordered: AI first, then framework. https://claude.ai/code/session_01QTp4SshuVmLAvvEGJe4TJd * blog: Going All In on AI Post 14 — the strategic case for making AI the primary direction. Covers the evolution from microservices framework to AI-native platform, why the timing is right (tool calling works, MCP is real, sponsors align), and what's not changing (framework still works, no agent framework complexity). https://claude.ai/code/session_01QTp4SshuVmLAvvEGJe4TJd --------- Co-authored-by: Claude <noreply@anthropic.com> |
||
|
|
16918669ca |
docs: restructure README — AI story completes before manual code (#2933)
Quick Start now flows through the full AI experience: generate → review → run → chat → grow (mid-conversation service generation). The reader sees the complete prompt-to-production story without interruption. "Writing Services" is a separate section below for developers who want to understand the framework underneath. Shows Go code, doc comments, @example tags, micro run, and scaffolding templates. Features table and CLI table reordered: AI first, then framework. https://claude.ai/code/session_01QTp4SshuVmLAvvEGJe4TJd Co-authored-by: Claude <noreply@anthropic.com> |
||
|
|
a357d1870d |
Update README and landing page with new AI-native hero image (#2932)
* docs: add binary install option to README quick start Show curl install.sh first (no Go required), go install second. Uses the existing install script at go-micro.dev/install.sh which downloads pre-built binaries from GitHub releases. https://claude.ai/code/session_01QTp4SshuVmLAvvEGJe4TJd * docs: regenerate hero image for new AI-native positioning New hero shows terminal running micro run with service generation, an AI agent orchestrating, and task/shipping/category service nodes. Matches the "Microservices That AI Agents Can Use" headline. https://claude.ai/code/session_01QTp4SshuVmLAvvEGJe4TJd * fix: replace video with hero image on landing page The old video autoplayed and covered the new hero image. Replace the video element with a static img tag showing the new AI-native hero graphic. https://claude.ai/code/session_01QTp4SshuVmLAvvEGJe4TJd --------- Co-authored-by: Claude <noreply@anthropic.com> |
||
|
|
91a545c6f2 |
Enhance README with binary install option and update hero image (#2931)
* docs: add binary install option to README quick start Show curl install.sh first (no Go required), go install second. Uses the existing install script at go-micro.dev/install.sh which downloads pre-built binaries from GitHub releases. https://claude.ai/code/session_01QTp4SshuVmLAvvEGJe4TJd * docs: regenerate hero image for new AI-native positioning New hero shows terminal running micro run with service generation, an AI agent orchestrating, and task/shipping/category service nodes. Matches the "Microservices That AI Agents Can Use" headline. https://claude.ai/code/session_01QTp4SshuVmLAvvEGJe4TJd --------- Co-authored-by: Claude <noreply@anthropic.com> |
||
|
|
00392aa1f2 |
docs: add binary install option to README quick start (#2930)
Show curl install.sh first (no Go required), go install second. Uses the existing install script at go-micro.dev/install.sh which downloads pre-built binaries from GitHub releases. https://claude.ai/code/session_01QTp4SshuVmLAvvEGJe4TJd Co-authored-by: Claude <noreply@anthropic.com> |
||
|
|
b54507710d |
Revise README with new install command and examples
Updated installation command and added usage examples. |
||
|
|
d541625e32 |
docs: unify README and website around one story (#2929)
Both surfaces now lead with the same line: "Go Micro is a framework for building microservices that AI agents can use." README: - Leads with prompt generation + chat (the differentiator) - Features as a compact table instead of paragraph-per-feature - CLI workflow table - Removed redundant sections, tightened to ~150 lines Website: - Hero: "Microservices That AI Agents Can Use" - Hero command: micro run --prompt instead of go get - Features grid reordered: AI tools, orchestration, generation first - First two-col section: describe/generate/run/chat story - Architecture and DX sections follow Both tell the same story in the same order: 1. What it is (microservices framework) 2. What makes it different (every service is an AI tool) 3. How you use it (prompt → run → chat) 4. What's underneath (registry, RPC, store — all pluggable) https://claude.ai/code/session_01QTp4SshuVmLAvvEGJe4TJd Co-authored-by: Claude <noreply@anthropic.com> |
||
|
|
7662b26b07 |
syntax highlighting (#2928)
* docs: add blog post 13 to blog index https://claude.ai/code/session_01QTp4SshuVmLAvvEGJe4TJd * docs: add syntax highlighting to blog post 13 code blocks Add language tags (bash, go, text) to all fenced code blocks so Rouge highlights them correctly. https://claude.ai/code/session_01QTp4SshuVmLAvvEGJe4TJd --------- Co-authored-by: Claude <noreply@anthropic.com> |
||
|
|
397010a82a |
docs: add blog post 13 to blog index (#2927)
https://claude.ai/code/session_01QTp4SshuVmLAvvEGJe4TJd Co-authored-by: Claude <noreply@anthropic.com> |
||
|
|
d3c4981326 |
Enhance AI service generation with prompt-based architecture and logic (#2926)
* feat: add micro new --prompt and micro run --prompt
Add AI-powered service generation: describe a system in natural
language and get real go-micro services with proto definitions,
handlers, doc comments, and MCP support.
micro new --prompt "a contact book with notes and tags" \
--provider anthropic
Generates:
contacts/ — CRUD service with name, email, phone fields
notes/ — notes linked to contacts
tags/ — tagging system
Each service gets:
proto/{name}.proto — domain model + CRUD endpoints
handler/{name}.go — in-memory store, @example tags for MCP
main.go — MCP-enabled, proper imports
go.mod + Makefile — compiles with go mod tidy + make proto
micro run --prompt does the same then starts all services.
The LLM designs the architecture (service names, fields, endpoints,
descriptions) and returns structured JSON. Code generation uses
the existing template patterns — the output is standard go-micro
code that compiles, runs, and is immediately callable via MCP
and micro chat. No AI dependency at runtime.
* feat: LLM generates real business logic with compile-fix loop
Rebuild the generate package so the LLM writes actual handler
code with business logic, not just CRUD scaffolding.
The flow is now:
1. LLM designs architecture (service names, fields, endpoints)
→ returns structured JSON
2. Proto, main.go, go.mod, Makefile generated deterministically
from the design (guaranteed to be correct)
3. go mod tidy + make proto compiles the protos
4. LLM generates handler code with REAL business logic
→ given the proto, endpoint descriptions, and go-micro patterns
5. go build — does it compile?
6. If no: feed errors back to LLM, get fixed code (up to 3 attempts)
7. If yes: service is ready
The handler prompt instructs the LLM to:
- Use sync.RWMutex for thread-safe in-memory state
- Include validation, edge cases, meaningful errors
- Write doc comments with @example tags for MCP
- Implement actual domain logic, not just map operations
Proto generation still uses deterministic templates (CRUD +
custom endpoints from the design spec) to guarantee correctness.
The compile-fix loop catches LLM mistakes automatically.
Both micro new --prompt and micro run --prompt use this flow.
* fix: handle edge cases in prompt-based generation
- Fix PATH for protoc-gen-micro in child processes
- Handle existing directories: skip structural files (main.go,
go.mod, Makefile) if dir exists, always regenerate proto,
only write placeholder handler if none exists
- Allow re-running micro new --prompt on same directory to
iterate on business logic without clobbering user edits
Tested end-to-end: "a simple todo list with tasks and categories"
generates 2 services (task-service, category-service) with real
business logic (validation, toggle complete, etc.), compiles
after 1 fix iteration, and runs with 6 MCP tools discovered.
* feat: auto-detect modified handlers on regeneration
Instead of requiring a --keep-handlers flag, the generate package now
tracks a SHA-256 hash of each generated handler in a .micro metadata
file. On re-run, if the user has edited the handler since generation,
it's left untouched. Unmodified handlers are regenerated normally.
https://claude.ai/code/session_01QTp4SshuVmLAvvEGJe4TJd
* feat: add tests, fix go.mod, gitignore, proto tracking, spinner
- Add 12 tests covering helpers, proto generation, hash tracking
- Fix go.mod: write minimal module file, let go mod tidy resolve deps
- Add .gitignore to prompt-generated services
- Protect user-edited proto files (same hash tracking as handlers)
- Add spinner during LLM calls so it doesn't look hung
https://claude.ai/code/session_01QTp4SshuVmLAvvEGJe4TJd
* feat: signal handling, existing service discovery, help text
- Ctrl+C during generation now cancels LLM calls immediately via
signal-aware context; re-run picks up where it left off
- Design() scans for existing services in the working directory and
includes their proto definitions in the prompt, so the LLM extends
the system rather than redesigning from scratch
- Updated --prompt help text with usage examples on both new and run
- Listed all supported providers in flag descriptions
- Added discoverExisting test
https://claude.ai/code/session_01QTp4SshuVmLAvvEGJe4TJd
* feat: show endpoints in run --prompt output, add micro chat hint
Print endpoint names and descriptions when designing services so users
see what was built. Add a micro chat hint to the run banner so users
know how to interact with their services after startup.
https://claude.ai/code/session_01QTp4SshuVmLAvvEGJe4TJd
* fix: generated go.mod uses go 1.24 with explicit go-micro require
go 1.22 with no explicit require caused Go to resolve sub-packages
(gateway/mcp, client, server) as separate modules, hitting stale v1.18
tags. Pin to go 1.24 + require go-micro.dev/v5 v5.24.0 so go mod tidy
resolves all sub-packages from the root module correctly.
Tested end-to-end: 4 services generated and compiled successfully.
https://claude.ai/code/session_01QTp4SshuVmLAvvEGJe4TJd
* fix: skip handler regeneration when proto unchanged
Compare proto hash before and after structure generation. If the proto
didn't change and the handler wasn't edited by the user, skip go mod
tidy, make proto, LLM handler generation, and compile-fix entirely.
Prints "(unchanged)" instead.
Reduces re-run of 4-service project from ~2 minutes to ~10 seconds.
https://claude.ai/code/session_01QTp4SshuVmLAvvEGJe4TJd
* feat: confirm design before generating code
Show the service design (names, endpoints) and prompt "Generate? [Y/n]"
before spending LLM time on handler generation. Applies to both
micro new --prompt and micro run --prompt. Default is yes (enter).
https://claude.ai/code/session_01QTp4SshuVmLAvvEGJe4TJd
* fix: use port :0 for MCP in generated multi-service projects
Each generated service had mcp.WithMCP(":3001") hardcoded, causing
port conflicts when running multiple services. Use :0 to auto-assign
a free port. micro run's central gateway handles unified MCP access.
https://claude.ai/code/session_01QTp4SshuVmLAvvEGJe4TJd
* feat: truncation detection, tool result display in chat
- Detect truncated LLM responses (unbalanced braces, doesn't end
with '}') and retry with a conciseness hint before falling through
to compile-fix
- Show tool call results in micro chat output (← for success, ✗ for
errors) so users can see what the LLM did
- Add Result/Error fields to ToolCall, populated by Anthropic provider
after tool execution
- Add isTruncated tests
Tested end-to-end with Anthropic: services generate, compile, start,
register, respond to RPC calls, and micro chat discovers and calls
tools correctly.
https://claude.ai/code/session_01QTp4SshuVmLAvvEGJe4TJd
* fix: Anthropic tool loop, service naming, chat tool results
Anthropic provider:
- Fix tool execution loop to properly iterate (was re-processing all
tool calls instead of only new ones each round)
- Clean assistant content blocks before sending back (strip 'id' from
text blocks that Anthropic rejects on input)
- Include tools in follow-up requests so model can make additional calls
- Loop up to 10 rounds until model responds with text only
Service naming:
- Strip '-service' suffix from micro.New() name so services register
as 'task', 'category' instead of 'taskservice', 'categoryservice'
Chat:
- Show tool results (← for success) and errors (✗) in chat output
Tested end-to-end: create task → list tasks works as multi-step
orchestration through micro chat with Anthropic Claude.
https://claude.ai/code/session_01QTp4SshuVmLAvvEGJe4TJd
* feat: blog post 13 — from prompt to production
Covers the full micro run --prompt flow: design, generate, compile-fix,
run, and chat orchestration. Positions agent-as-orchestrator as the
answer to service coordination.
https://claude.ai/code/session_01QTp4SshuVmLAvvEGJe4TJd
* fix: timeouts, max_tokens, TTY detection, smaller services
- Add 60s timeout on design, 90s on handler generation, 60s on
compile-fix LLM calls so hung providers don't block forever
- Bump Anthropic max_tokens from 4096 to 8192 to reduce truncation
- Add TTY detection: spinner prints static message in non-TTY (CI/pipes)
instead of ANSI escape codes
- Tighten prompts: max 200 lines per handler, 2-4 services, 5-8 fields,
explicit "services don't call each other" rule
https://claude.ai/code/session_01QTp4SshuVmLAvvEGJe4TJd
* feat: chat suggests creating services when capabilities are missing
Update system prompt with the list of available services. When the user
asks for something no existing service can handle, the agent explains
what's available and suggests the exact micro new --prompt command to
create the missing service.
This is the natural evolution path: start with a few services, talk to
them via chat, and when the domain grows, the agent tells you what to
add. Each service stays small and focused.
https://claude.ai/code/session_01QTp4SshuVmLAvvEGJe4TJd
* feat: chat generates and starts services inline, drop -service suffix
Chat agent now has a micro_generate_service tool. When the user asks
for a capability that doesn't exist, the agent generates the service,
compiles it, starts it as a background process, waits for registration,
re-discovers tools, and uses the new endpoints immediately — all within
the conversation.
Service naming: design prompt now instructs LLM to return names without
'-service' suffix (e.g. 'task' not 'task-service'). buildMain keeps
TrimSuffix as safety net for backward compatibility.
Spawned processes are cleaned up when chat exits.
https://claude.ai/code/session_01QTp4SshuVmLAvvEGJe4TJd
* docs: rewrite blog post 13 with inline service generation
Updated to reflect the full UX: services generate and start within
the chat conversation. Added the shipping example showing the agent
creating a service mid-conversation. Removed -service suffix from
all examples. Tightened the narrative around agent-as-orchestrator.
https://claude.ai/code/session_01QTp4SshuVmLAvvEGJe4TJd
* feat: persistent storage, README quickstart, auto-detect new services
Storage: generated handlers now use go-micro's store package instead
of in-memory maps. Data persists across restarts. The handler prompt
includes store API examples so the LLM generates correct store usage.
README: added "Generate From a Prompt" section with micro run --prompt
and micro chat examples, linking to blog post 13.
Watcher: micro run now scans for new service directories every 5s. When
micro chat generates a service, micro run detects the new directory,
builds it, starts it, and adds it to the watcher — fully automatic.
Added AddDir/Dirs methods to the watcher.
Blog: updated post 13 with persistent storage example and watcher note.
https://claude.ai/code/session_01QTp4SshuVmLAvvEGJe4TJd
---------
Co-authored-by: Claude <noreply@anthropic.com>
|
||
|
|
96280678ee |
Expose framework primitives via API gateway and MCP with auth control (#2925)
* feat: expose framework primitives via API gateway and MCP
Add registry, store, and broker as both HTTP routes and MCP tools
so AI agents and HTTP clients can inspect and operate the framework.
API gateway (/micro/* namespace):
GET /micro/registry List registered services
GET /micro/registry/{name} Describe a service
GET /micro/store List store keys
GET /micro/store/{key} Read a record
POST /micro/store/{key} Write a record
POST /micro/broker/{topic} Publish a message
MCP gateway (micro_* tool prefix):
micro_registry_list List services
micro_registry_get Describe a service
micro_store_list List keys
micro_store_read Read a record
micro_store_write Write a record
micro_broker_publish Publish a message
Framework tools use a Handler field on the MCP Tool struct for
direct dispatch (no RPC). Service tools continue to use RPC.
Rate limiters and circuit breakers are applied to framework
tools the same as service tools.
* fix: make framework internals opt-in on API and MCP gateways
Framework primitives (registry, broker, store) are now only
exposed when explicitly enabled:
API gateway: micro api --internal
MCP gateway: Options{Internal: true}
Off by default — user services are always exposed, framework
internals require the flag. Banner output only shows framework
routes when enabled.
* fix: always expose framework internals, gate by auth in production
Revert the --internal flag approach. Framework primitives (registry,
broker, store) are now always exposed:
- micro api: /micro/* routes always available (dev tool)
- MCP gateway: micro_* tools always registered. When Auth is
configured (production), they require micro:admin scope.
Without Auth (dev), they're open — same as all other tools.
This follows the existing pattern: micro run/api = dev (open),
micro server = production (auth + scopes). Framework internals
follow the same security model as user services.
Remove the Internal option from MCP Options. Remove --internal
flag from micro api.
Note: scope persistence depends on the store backend. The default
in-memory store does not survive restarts. Use MICRO_STORE=file
for persistent scopes in production.
* fix: correct DefaultStore comment — it's file-backed, not memory
* fix(server): don't recreate deleted admin user on restart
When the default admin account is deleted via the dashboard, set
a marker key (auth/.admin-deleted) in the store. On startup, skip
admin creation if the marker exists. This prevents the default
admin/micro credentials from reappearing after restart when the
user has intentionally removed them.
* fix: improve agent playground first-run UX and fix doc 404s
Agent playground:
- Add setup hint in empty state explaining how to get started
(click Settings, enter API key, type a prompt)
- Hide hint automatically when API key is already configured
- Add all 7 providers to dropdown (was only OpenAI + Anthropic)
- Include CLI fallback suggestion (micro chat)
Docs:
- Fix .md links to .html across all doc pages — Jekyll serves
.html files, not .md. Fixes 404s including the micro run guide.
---------
Co-authored-by: Claude <noreply@anthropic.com>
|
||
|
|
69fc228c73 |
Enhance CLI color output and expose framework primitives via API (#2924)
* feat: expose framework primitives via API gateway and MCP
Add registry, store, and broker as both HTTP routes and MCP tools
so AI agents and HTTP clients can inspect and operate the framework.
API gateway (/micro/* namespace):
GET /micro/registry List registered services
GET /micro/registry/{name} Describe a service
GET /micro/store List store keys
GET /micro/store/{key} Read a record
POST /micro/store/{key} Write a record
POST /micro/broker/{topic} Publish a message
MCP gateway (micro_* tool prefix):
micro_registry_list List services
micro_registry_get Describe a service
micro_store_list List keys
micro_store_read Read a record
micro_store_write Write a record
micro_broker_publish Publish a message
Framework tools use a Handler field on the MCP Tool struct for
direct dispatch (no RPC). Service tools continue to use RPC.
Rate limiters and circuit breakers are applied to framework
tools the same as service tools.
* fix: make framework internals opt-in on API and MCP gateways
Framework primitives (registry, broker, store) are now only
exposed when explicitly enabled:
API gateway: micro api --internal
MCP gateway: Options{Internal: true}
Off by default — user services are always exposed, framework
internals require the flag. Banner output only shows framework
routes when enabled.
* fix: always expose framework internals, gate by auth in production
Revert the --internal flag approach. Framework primitives (registry,
broker, store) are now always exposed:
- micro api: /micro/* routes always available (dev tool)
- MCP gateway: micro_* tools always registered. When Auth is
configured (production), they require micro:admin scope.
Without Auth (dev), they're open — same as all other tools.
This follows the existing pattern: micro run/api = dev (open),
micro server = production (auth + scopes). Framework internals
follow the same security model as user services.
Remove the Internal option from MCP Options. Remove --internal
flag from micro api.
Note: scope persistence depends on the store backend. The default
in-memory store does not survive restarts. Use MICRO_STORE=file
for persistent scopes in production.
* fix: correct DefaultStore comment — it's file-backed, not memory
* fix(server): don't recreate deleted admin user on restart
When the default admin account is deleted via the dashboard, set
a marker key (auth/.admin-deleted) in the store. On startup, skip
admin creation if the marker exists. This prevents the default
admin/micro credentials from reappearing after restart when the
user has intentionally removed them.
---------
Co-authored-by: Claude <noreply@anthropic.com>
|
||
|
|
5d7609027b |
Enhance CLI with color output and add teardown blog post (#2923)
* feat(cli): add color output to micro chat and micro api micro chat: - Startup banner matching micro run style: bold header, cyan provider/model, green dots for each discovered tool endpoint - Cyan bold prompt (> ) instead of plain - Yellow arrow (→) with dimmed tool name for tool calls - Red "error:" prefix for errors - Dimmed "(history cleared)" for reset micro api: - Startup banner matching micro run style: bold header, cyan address, colored HTTP methods (green GET, yellow POST) Brings the CLI UX closer to what the generated terminal screenshot depicts — color-coded, professional, readable. * feat(cli): adopt consistent color output across all commands Apply the same banner/output style across the remaining commands: micro new: bold header, cyan service name, green ✓, cyan URLs micro build: green ✓ checkmarks, cyan file paths micro deploy: bold header, cyan target micro mcp: bold header, green dots per tool, dimmed count micro flow: bold header, cyan flow/topic/provider All commands now follow the micro run/chat/api pattern: bold header, cyan values, green status indicators, dimmed hints. * docs: add "Tools as Services" blog post Write blog/12 — connects the AI story back to Go Micro's original design: services were always self-describing, named, and uniformly callable. The path from API gateway to MCP to LLM tools is the same pattern — read the registry, present services in a format the consumer understands, route calls back. Covers the access layer pattern (HTTP, web, CLI, MCP, chat), why doc comments became functional in the AI era, and how the framework primitives (registry, broker, store) could all become tools using the same mechanism. Add to blog index, link forward from blog/11. --------- Co-authored-by: Claude <noreply@anthropic.com> |
||
|
|
5601be009a |
docs: add "Build Your Own AI Agent CLI" teardown blog post (#2921)
Write blog/11 — a teardown of micro chat showing how to build an LLM tool-calling agent in ~150 lines. Walks through the four pieces: discover tools, create the model, track conversation, run the loop. Uses the actual chat.go source. Ends with extension ideas and a "make it yours" framing. Add to blog index, link forward from blog/10. Co-authored-by: Claude <noreply@anthropic.com> |
||
|
|
888dbbca4a |
Refactor AI tool handling and enhance CLI command documentation (#2920)
* refactor(ai): rename ToolSet to Tools, simplify wiring with WithTools
Move tool discovery/execution fully into the ai package as ai.Tools
(formerly ai.ToolSet), and simplify the usage model:
- NewTools(reg, ai.ToolClient(c)) takes the execution client as an
option instead of threading it through Handler(c) per call
- New ai.WithTools(tools) option wires the tool handler into a model
in one call, replacing ai.WithToolHandler(set.Handler(c))
- ai.DiscoverTools(reg) for one-shot discovery
Before:
set := ai.NewToolSet(reg)
list, _ := set.Discover()
m := ai.New(p, ai.WithToolHandler(set.Handler(client)))
After:
tools := ai.NewTools(reg, ai.ToolClient(client))
list, _ := tools.Discover()
m := ai.New(p, ai.WithTools(tools))
Update ai/flow, micro chat, README, ai integration doc, Atlas Cloud
guide, and blog posts 3/8/9/10.
* feat(cli): add per-interface commands (registry, broker, store, config)
Map go-micro's core interfaces onto the CLI so the framework's
building blocks are inspectable and manipulable from the terminal:
micro registry list/get/watch service discovery
micro broker publish/subscribe pub/sub messaging
micro store read/write/delete/list persistence
micro config get/dump dynamic config (from env)
Structured pluggably in cmd/micro/resource: each interface is one
file exposing a Command() func, all wired through a commandFuncs
slice in resource.go. Adding a new resource command is a single
file plus one slice entry. Shared printJSON/fail helpers keep
output and errors consistent across commands.
Each command's verbs mirror the interface methods. Output is JSON
for structured data, raw for single values. Update README and
getting-started with an "inspecting the framework" section.
* docs: update CLI README with all new commands
Add documentation for commands that were missing from the CLI README:
- micro new --template (crud, pubsub, api)
- micro api (standalone HTTP gateway)
- micro registry list/get/watch
- micro broker publish/subscribe
- micro store read/write/delete/list
- micro config get/dump
- micro chat (interactive LLM agent)
- micro flow run/exec (event-driven orchestration)
- micro mcp serve/list/test
Organized into sections: API Gateway, Inspecting the Framework
(registry, broker, store, config), and AI & Agents (chat, flow, mcp).
* refactor(ai): move History from caller to Request field
History is now pure state (no Generate method). Instead, pass it
via Request.History and call ai.Generate(ctx, model, req):
Before:
hist := ai.NewHistory("system prompt", 50)
resp, _ := hist.Generate(ctx, model, prompt, tools)
After:
hist := ai.NewHistory(50)
resp, _ := ai.Generate(ctx, model, &ai.Request{
Prompt: prompt,
SystemPrompt: "system prompt",
Tools: tools,
History: hist,
})
The model is always the thing you call. History is context you
pass in. ai.Generate() handles the bookkeeping: prepends
accumulated messages before the call, records the exchange after.
NewHistory no longer takes a system prompt (it belongs on the
Request, where it always did).
Update micro chat, ai/flow, and all blog posts/docs.
* refactor(ai): make History a plain message accumulator
History no longer has Generate or touches the model. It's just
Add/Messages/Reset/Len with truncation — a helper for building
Request.Messages across turns.
Before:
hist := ai.NewHistory(50)
resp, _ := ai.Generate(ctx, m, &ai.Request{History: hist, ...})
After:
hist := ai.NewHistory(50)
hist.Add("user", prompt)
resp, _ := m.Generate(ctx, &ai.Request{Messages: hist.Messages(), ...})
hist.Add("assistant", resp.Reply)
Remove History field from Request. Remove package-level
ai.Generate(ctx, model, req) wrapper — users call m.Generate()
directly, which is the interface method. History is a convenience
for accumulating messages, not a participant in generation.
Update micro chat, ai/flow, blog posts 9 and 10.
---------
Co-authored-by: Claude <noreply@anthropic.com>
|
||
|
|
f48d81c760 |
Cli commands (#2919)
* refactor(ai): rename ToolSet to Tools, simplify wiring with WithTools Move tool discovery/execution fully into the ai package as ai.Tools (formerly ai.ToolSet), and simplify the usage model: - NewTools(reg, ai.ToolClient(c)) takes the execution client as an option instead of threading it through Handler(c) per call - New ai.WithTools(tools) option wires the tool handler into a model in one call, replacing ai.WithToolHandler(set.Handler(c)) - ai.DiscoverTools(reg) for one-shot discovery Before: set := ai.NewToolSet(reg) list, _ := set.Discover() m := ai.New(p, ai.WithToolHandler(set.Handler(client))) After: tools := ai.NewTools(reg, ai.ToolClient(client)) list, _ := tools.Discover() m := ai.New(p, ai.WithTools(tools)) Update ai/flow, micro chat, README, ai integration doc, Atlas Cloud guide, and blog posts 3/8/9/10. * feat(cli): add per-interface commands (registry, broker, store, config) Map go-micro's core interfaces onto the CLI so the framework's building blocks are inspectable and manipulable from the terminal: micro registry list/get/watch service discovery micro broker publish/subscribe pub/sub messaging micro store read/write/delete/list persistence micro config get/dump dynamic config (from env) Structured pluggably in cmd/micro/resource: each interface is one file exposing a Command() func, all wired through a commandFuncs slice in resource.go. Adding a new resource command is a single file plus one slice entry. Shared printJSON/fail helpers keep output and errors consistent across commands. Each command's verbs mirror the interface methods. Output is JSON for structured data, raw for single values. Update README and getting-started with an "inspecting the framework" section. * docs: update CLI README with all new commands Add documentation for commands that were missing from the CLI README: - micro new --template (crud, pubsub, api) - micro api (standalone HTTP gateway) - micro registry list/get/watch - micro broker publish/subscribe - micro store read/write/delete/list - micro config get/dump - micro chat (interactive LLM agent) - micro flow run/exec (event-driven orchestration) - micro mcp serve/list/test Organized into sections: API Gateway, Inspecting the Framework (registry, broker, store, config), and AI & Agents (chat, flow, mcp). --------- Co-authored-by: Claude <noreply@anthropic.com> |
||
|
|
3acf74a29a |
Refactor tool management and add CLI commands for interfaces (#2918)
* refactor(ai): rename ToolSet to Tools, simplify wiring with WithTools Move tool discovery/execution fully into the ai package as ai.Tools (formerly ai.ToolSet), and simplify the usage model: - NewTools(reg, ai.ToolClient(c)) takes the execution client as an option instead of threading it through Handler(c) per call - New ai.WithTools(tools) option wires the tool handler into a model in one call, replacing ai.WithToolHandler(set.Handler(c)) - ai.DiscoverTools(reg) for one-shot discovery Before: set := ai.NewToolSet(reg) list, _ := set.Discover() m := ai.New(p, ai.WithToolHandler(set.Handler(client))) After: tools := ai.NewTools(reg, ai.ToolClient(client)) list, _ := tools.Discover() m := ai.New(p, ai.WithTools(tools)) Update ai/flow, micro chat, README, ai integration doc, Atlas Cloud guide, and blog posts 3/8/9/10. * feat(cli): add per-interface commands (registry, broker, store, config) Map go-micro's core interfaces onto the CLI so the framework's building blocks are inspectable and manipulable from the terminal: micro registry list/get/watch service discovery micro broker publish/subscribe pub/sub messaging micro store read/write/delete/list persistence micro config get/dump dynamic config (from env) Structured pluggably in cmd/micro/resource: each interface is one file exposing a Command() func, all wired through a commandFuncs slice in resource.go. Adding a new resource command is a single file plus one slice entry. Shared printJSON/fail helpers keep output and errors consistent across commands. Each command's verbs mirror the interface methods. Output is JSON for structured data, raw for single values. Update README and getting-started with an "inspecting the framework" section. --------- Co-authored-by: Claude <noreply@anthropic.com> |
||
|
|
c4b4cbef25 |
refactor(ai): rename ToolSet to Tools, simplify wiring with WithTools (#2917)
Move tool discovery/execution fully into the ai package as ai.Tools (formerly ai.ToolSet), and simplify the usage model: - NewTools(reg, ai.ToolClient(c)) takes the execution client as an option instead of threading it through Handler(c) per call - New ai.WithTools(tools) option wires the tool handler into a model in one call, replacing ai.WithToolHandler(set.Handler(c)) - ai.DiscoverTools(reg) for one-shot discovery Before: set := ai.NewToolSet(reg) list, _ := set.Discover() m := ai.New(p, ai.WithToolHandler(set.Handler(client))) After: tools := ai.NewTools(reg, ai.ToolClient(client)) list, _ := tools.Discover() m := ai.New(p, ai.WithTools(tools)) Update ai/flow, micro chat, README, ai integration doc, Atlas Cloud guide, and blog posts 3/8/9/10. Co-authored-by: Claude <noreply@anthropic.com> |
||
|
|
a9421e5b7e |
Update logo design, add AI integration documentation and blog post (#2916)
* feat: update Go Micro logo to interconnected nodes design Replace the text-on-blue-square logo with a modern icon: three teal nodes connected in a triangle, representing distributed systems. Generated via Atlas Cloud. Clean at all sizes — works as GitHub avatar, favicon, and nav bar icon. * feat: new logo, AI integration architecture doc, and landing page CTA Update logo to triangle-nodes icon + "Go Micro" text wordmark. Save icon-only variant for favicon/avatar use. Add docs/ai-integration.md — a single page that explains how the AI stack fits together: services → registry → MCP gateway → ai/tools → ai.Model → micro chat. Layer-by-layer with code examples, provider table, and "what you don't need" section. Add AI Integration to docs sidebar navigation (after Getting Started). Update the landing page AI section with a direct CTA button linking to the new doc. * fix: restore original logo and add border-radius to all renders Revert logo to original. Add border-radius: 8px to the logo img in the landing page nav, docs layout nav, and blog layout nav so the square logo renders with rounded corners everywhere. Remove unused icon.png. * docs: add micro chat blog post Write blog/10 — a dedicated post for micro chat covering: - What it does (interactive LLM agent for services) - How it works (ai/tools → ai.History → ai.Model stack) - Multi-turn conversation examples - All provider options and env vars - Single prompt mode for scripting - Why it works (registry metadata + doc comments = tool descriptions) - Programmatic usage with the same building blocks - Link to micro flow as the event-driven counterpart Add to blog index. Update blog 9 nav to link forward. --------- Co-authored-by: Claude <noreply@anthropic.com> |
||
|
|
03f912f68a | Add AtlasCloud sponsor logo to README | ||
|
|
594ee107b7 |
Clean up README.md formatting
Removed unnecessary whitespace and line breaks in README. |
||
|
|
2f164595f2 |
Add Atlas Cloud logo link to README
Added an image link for Atlas Cloud to the README. |
||
|
|
740980a9cc |
Clean up whitespace in README.md
Removed extra whitespace before the second image link. |
||
|
|
3d2d9acd68 | Fix formatting issues in README.md | ||
|
|
88aa0cc666 |
Update logo, add AI integration docs, and enhance CLI features (#2915)
* feat: update Go Micro logo to interconnected nodes design
Replace the text-on-blue-square logo with a modern icon: three
teal nodes connected in a triangle, representing distributed
systems. Generated via Atlas Cloud. Clean at all sizes — works
as GitHub avatar, favicon, and nav bar icon.
* feat: new logo, AI integration architecture doc, and landing page CTA
Update logo to triangle-nodes icon + "Go Micro" text wordmark.
Save icon-only variant for favicon/avatar use.
Add docs/ai-integration.md — a single page that explains how the
AI stack fits together: services → registry → MCP gateway →
ai/tools → ai.Model → micro chat. Layer-by-layer with code
examples, provider table, and "what you don't need" section.
Add AI Integration to docs sidebar navigation (after Getting
Started). Update the landing page AI section with a direct CTA
button linking to the new doc.
* fix: restore original logo and add border-radius to all renders
Revert logo to original. Add border-radius: 8px to the logo img
in the landing page nav, docs layout nav, and blog layout nav
so the square logo renders with rounded corners everywhere.
Remove unused icon.png.
* feat(ai): add ai/flow package and micro flow CLI
Add ai/flow — event-driven LLM orchestration for go-micro. A Flow
subscribes to a broker topic, discovers services as tools, and
feeds each event into an LLM that decides which RPCs to call.
Key types:
- flow.New(name, opts...) creates a flow with trigger topic,
prompt template, provider config
- flow.Register(registry, broker, client) wires it into a service
- flow.Execute(ctx, data) runs the flow once (for testing/CLI)
- flow.Results() returns execution history
Add micro flow CLI with two subcommands:
- micro flow run: subscribe to a topic and react to events
- micro flow exec: one-shot execution with inline data
Both output JSON results with flow name, prompt, tool calls,
reply, answer, duration, and errors.
Example:
micro flow run --trigger events.user.created \
--prompt "New user: {{.Data}}. Send welcome email." \
--provider anthropic
micro flow exec --prompt "List all users" --provider anthropic
* docs: update flows blog post with ai/flow package and CLI examples
Add "Update: We Built It" section to blog/9 showing the ai/flow
package API, CLI usage for both event-driven and one-shot modes,
and what it does/doesn't do. Links the conceptual discussion to
the shipped implementation.
* feat(cli): add micro api gateway command, clarify run vs server
Add 'micro api' — a standalone lightweight HTTP-to-RPC gateway:
- POST /{service}/{endpoint} proxies to RPC calls
- GET / lists all services and endpoints
- GET /{service} describes a service
- GET /health returns ok
- Supports Micro-Endpoint header for endpoint routing
- No dashboard, no auth, no hot reload — just the proxy
Update help text to clarify the three gateway modes:
- micro api: bare HTTP-to-RPC proxy
- micro run: development mode (hot reload + gateway + agent playground)
- micro server: production mode (dashboard + auth + JWT)
* docs: update README, getting started, and AI integration for all new features
Update the development workflow table in both README and getting
started to include all CLI commands: micro new --template,
micro api, micro chat, micro flow, micro call.
Getting started:
- Add CRUD template example to quick start
- Update workflow table with 8 stages
- Add AI Integration, MCP, and gRPC Interop to Next Steps
README:
- Add template flag to quick start example
- Update workflow table
- Reorder User Guides with AI Integration prominent
AI Integration doc:
- Update stack diagram to include micro api and ai/flow
- Add micro flow section with Go API and CLI examples
- Add micro api section
- Renumber layers (now 8 instead of 7)
---------
Co-authored-by: Claude <noreply@anthropic.com>
|
||
|
|
601c67675f |
Update logo, add AI integration docs, and enhance CLI features (#2914)
* feat: update Go Micro logo to interconnected nodes design
Replace the text-on-blue-square logo with a modern icon: three
teal nodes connected in a triangle, representing distributed
systems. Generated via Atlas Cloud. Clean at all sizes — works
as GitHub avatar, favicon, and nav bar icon.
* feat: new logo, AI integration architecture doc, and landing page CTA
Update logo to triangle-nodes icon + "Go Micro" text wordmark.
Save icon-only variant for favicon/avatar use.
Add docs/ai-integration.md — a single page that explains how the
AI stack fits together: services → registry → MCP gateway →
ai/tools → ai.Model → micro chat. Layer-by-layer with code
examples, provider table, and "what you don't need" section.
Add AI Integration to docs sidebar navigation (after Getting
Started). Update the landing page AI section with a direct CTA
button linking to the new doc.
* fix: restore original logo and add border-radius to all renders
Revert logo to original. Add border-radius: 8px to the logo img
in the landing page nav, docs layout nav, and blog layout nav
so the square logo renders with rounded corners everywhere.
Remove unused icon.png.
* feat(ai): add ai/flow package and micro flow CLI
Add ai/flow — event-driven LLM orchestration for go-micro. A Flow
subscribes to a broker topic, discovers services as tools, and
feeds each event into an LLM that decides which RPCs to call.
Key types:
- flow.New(name, opts...) creates a flow with trigger topic,
prompt template, provider config
- flow.Register(registry, broker, client) wires it into a service
- flow.Execute(ctx, data) runs the flow once (for testing/CLI)
- flow.Results() returns execution history
Add micro flow CLI with two subcommands:
- micro flow run: subscribe to a topic and react to events
- micro flow exec: one-shot execution with inline data
Both output JSON results with flow name, prompt, tool calls,
reply, answer, duration, and errors.
Example:
micro flow run --trigger events.user.created \
--prompt "New user: {{.Data}}. Send welcome email." \
--provider anthropic
micro flow exec --prompt "List all users" --provider anthropic
* docs: update flows blog post with ai/flow package and CLI examples
Add "Update: We Built It" section to blog/9 showing the ai/flow
package API, CLI usage for both event-driven and one-shot modes,
and what it does/doesn't do. Links the conceptual discussion to
the shipped implementation.
* feat(cli): add micro api gateway command, clarify run vs server
Add 'micro api' — a standalone lightweight HTTP-to-RPC gateway:
- POST /{service}/{endpoint} proxies to RPC calls
- GET / lists all services and endpoints
- GET /{service} describes a service
- GET /health returns ok
- Supports Micro-Endpoint header for endpoint routing
- No dashboard, no auth, no hot reload — just the proxy
Update help text to clarify the three gateway modes:
- micro api: bare HTTP-to-RPC proxy
- micro run: development mode (hot reload + gateway + agent playground)
- micro server: production mode (dashboard + auth + JWT)
---------
Co-authored-by: Claude <noreply@anthropic.com>
|
||
|
|
b97f45106d |
Update logo, add AI integration docs, and implement ai/flow package (#2913)
* feat: update Go Micro logo to interconnected nodes design
Replace the text-on-blue-square logo with a modern icon: three
teal nodes connected in a triangle, representing distributed
systems. Generated via Atlas Cloud. Clean at all sizes — works
as GitHub avatar, favicon, and nav bar icon.
* feat: new logo, AI integration architecture doc, and landing page CTA
Update logo to triangle-nodes icon + "Go Micro" text wordmark.
Save icon-only variant for favicon/avatar use.
Add docs/ai-integration.md — a single page that explains how the
AI stack fits together: services → registry → MCP gateway →
ai/tools → ai.Model → micro chat. Layer-by-layer with code
examples, provider table, and "what you don't need" section.
Add AI Integration to docs sidebar navigation (after Getting
Started). Update the landing page AI section with a direct CTA
button linking to the new doc.
* fix: restore original logo and add border-radius to all renders
Revert logo to original. Add border-radius: 8px to the logo img
in the landing page nav, docs layout nav, and blog layout nav
so the square logo renders with rounded corners everywhere.
Remove unused icon.png.
* feat(ai): add ai/flow package and micro flow CLI
Add ai/flow — event-driven LLM orchestration for go-micro. A Flow
subscribes to a broker topic, discovers services as tools, and
feeds each event into an LLM that decides which RPCs to call.
Key types:
- flow.New(name, opts...) creates a flow with trigger topic,
prompt template, provider config
- flow.Register(registry, broker, client) wires it into a service
- flow.Execute(ctx, data) runs the flow once (for testing/CLI)
- flow.Results() returns execution history
Add micro flow CLI with two subcommands:
- micro flow run: subscribe to a topic and react to events
- micro flow exec: one-shot execution with inline data
Both output JSON results with flow name, prompt, tool calls,
reply, answer, duration, and errors.
Example:
micro flow run --trigger events.user.created \
--prompt "New user: {{.Data}}. Send welcome email." \
--provider anthropic
micro flow exec --prompt "List all users" --provider anthropic
* docs: update flows blog post with ai/flow package and CLI examples
Add "Update: We Built It" section to blog/9 showing the ai/flow
package API, CLI usage for both event-driven and one-shot modes,
and what it does/doesn't do. Links the conceptual discussion to
the shipped implementation.
---------
Co-authored-by: Claude <noreply@anthropic.com>
|
||
|
|
28fa44b2ca |
Update logo design, enhance AI integration docs, and simplify navigation (#2912)
* feat: update Go Micro logo to interconnected nodes design Replace the text-on-blue-square logo with a modern icon: three teal nodes connected in a triangle, representing distributed systems. Generated via Atlas Cloud. Clean at all sizes — works as GitHub avatar, favicon, and nav bar icon. * feat: new logo, AI integration architecture doc, and landing page CTA Update logo to triangle-nodes icon + "Go Micro" text wordmark. Save icon-only variant for favicon/avatar use. Add docs/ai-integration.md — a single page that explains how the AI stack fits together: services → registry → MCP gateway → ai/tools → ai.Model → micro chat. Layer-by-layer with code examples, provider table, and "what you don't need" section. Add AI Integration to docs sidebar navigation (after Getting Started). Update the landing page AI section with a direct CTA button linking to the new doc. * fix: restore original logo and add border-radius to all renders Revert logo to original. Add border-radius: 8px to the logo img in the landing page nav, docs layout nav, and blog layout nav so the square logo renders with rounded corners everywhere. Remove unused icon.png. * fix: trim nav to 3 links across all layouts Remove Reference and Home links from nav across landing page, docs layout, and blog layout. Keep only Docs, Blog, GitHub — the three things people actually need. Fixes crowded nav on mobile where 5 links plus a menu button didn't fit. --------- Co-authored-by: Claude <noreply@anthropic.com> |
||
|
|
985621f4b4 |
AI integration updates (#2911)
* feat: update Go Micro logo to interconnected nodes design Replace the text-on-blue-square logo with a modern icon: three teal nodes connected in a triangle, representing distributed systems. Generated via Atlas Cloud. Clean at all sizes — works as GitHub avatar, favicon, and nav bar icon. * feat: new logo, AI integration architecture doc, and landing page CTA Update logo to triangle-nodes icon + "Go Micro" text wordmark. Save icon-only variant for favicon/avatar use. Add docs/ai-integration.md — a single page that explains how the AI stack fits together: services → registry → MCP gateway → ai/tools → ai.Model → micro chat. Layer-by-layer with code examples, provider table, and "what you don't need" section. Add AI Integration to docs sidebar navigation (after Getting Started). Update the landing page AI section with a direct CTA button linking to the new doc. * fix: restore original logo and add border-radius to all renders Revert logo to original. Add border-radius: 8px to the logo img in the landing page nav, docs layout nav, and blog layout nav so the square logo renders with rounded corners everywhere. Remove unused icon.png. --------- Co-authored-by: Claude <noreply@anthropic.com> |
||
|
|
7a1ab14847 |
docs: rewrite Anthropic blog post with updated content and new header image (#2910)
Rewrite blog/3 to reflect current state of the project: - Update numbers (7 providers, image/video support, micro chat) - Add "What Came After" section covering everything shipped since - Tighten prose, remove stale roadmap percentages - Replace generic MCP image with Claude-themed header generated via Atlas Cloud (orange AI orb connecting to service nodes) - Streamline code examples - Update star count and Try It section Co-authored-by: Claude <noreply@anthropic.com> |
||
|
|
c26d74a8a1 |
Add CRUD, pub/sub, and API gateway templates; update AI features (#2909)
* feat(website): redesign docs and blog layouts, add blog header images Redesign both layouts to match the new landing page: - Consistent nav bar with logo, Docs, Blog, GitHub, Reference, Home - Consistent footer with copyright and links - CSS custom properties for theming - Updated typography, spacing, and code block styling - Active sidebar link highlighting in docs - Dark mode support preserved Generate 4 blog header images via Atlas Cloud: - blog-deploy.png for post 1 (micro deploy) - blog-mcp.png for posts 2, 3, 7 (MCP-related) - blog-agents-demo.png for post 4 (agents demo) - blog-dx.png for post 5 (DX cleanup) - Reuse data-model.png for post 6 (model package) All 7 existing blog posts now have header images. * fix(website): prevent horizontal scroll on mobile landing page Add overflow-x: hidden on html and body. Set max-width: 100% and height: auto on all section and two-col images. Add overflow: hidden to .two-col grid. Constrain hero pre with max-width and overflow-x. Reduce font sizes and padding at mobile breakpoint. * feat(website): add images to remaining core doc pages Generate 5 more images via Atlas Cloud for docs: - registry.png: service discovery diagram - broker.png: pub/sub message broker pattern - transport.png: multi-transport layers (HTTP, gRPC, NATS) - config.png: dynamic configuration from multiple sources - observability.png: monitoring dashboard with metrics/traces Add images to registry.md, broker.md, transport.md, config.md, observability.md, and architecture.md. All 11 main doc pages now have header images. * feat: add sponsor logos to landing page, README images, and flows blog post Add Anthropic and Atlas Cloud sponsor logos to the landing page with links to their respective blog posts. Logos display at 0.7 opacity with hover effect. Add architecture and MCP agent images to the GitHub README for the Overview and MCP sections. Write blog post 9: "From Chat to Flows" — explores the concept of LLM-powered service orchestration. Compares micro chat's interactive model with persistent event-driven flows, shows how the existing building blocks (ai/tools, History, broker) could compose into a flow engine, discusses tradeoffs vs traditional orchestration (Step Functions, Temporal), and includes a working 15-line code example. Explicitly positions it as a concept for community feedback, not an announcement. * feat(website): add animated hero video to landing page Generate a 6-second hero video via Atlas Cloud's image-to-video API (gemini-omni-flash). Shows the microservices network diagram animating with data flowing between nodes. Replace the static hero image with an autoplay muted looping video element. Falls back to the static image via poster attribute and img fallback for browsers without video support. * feat(ai): add VideoModel interface with Atlas Cloud provider Add ai.VideoModel interface for video generation alongside Model and ImageModel. Supports text-to-video and image-to-video via VideoRequest with prompt, reference images, duration, aspect ratio, and resolution fields. Implement GenerateVideo for Atlas Cloud using their async API: POST /api/v1/model/generateVideo → poll /api/v1/model/prediction. Default model is gemini-omni-flash image-to-video. Polls every 5 seconds until completion or context cancellation. Register Atlas Cloud as a video provider via ai.RegisterVideo. Add 3 tests: registration, no-key error, compile-time interface check. Update ai/README.md with VideoModel docs. The ai package now covers all three modalities: - Model (text) — 7 providers - ImageModel (image) — 2 providers (Atlas Cloud, OpenAI) - VideoModel (video) — 1 provider (Atlas Cloud) --------- Co-authored-by: Claude <noreply@anthropic.com> |
||
|
|
669481224c |
Enhance AI features with ImageModel, History, and website updates (#2907)
* feat(cli): add CRUD, pub/sub, and API gateway templates for micro new
Add --template flag to 'micro new' with three preset templates:
- crud: CRUD service with Create/Read/Update/Delete/List, in-memory
store with sync.RWMutex, UUID generation, pagination, and doc
comments with @example tags for MCP tool discovery.
- pubsub: Event-driven service with Publish/Stats RPCs and a
Subscribe method that hooks into the broker. Includes event
types with ID, type, source, data, and timestamp.
- api: API gateway service with Health and Endpoint RPCs, an
internal HTTP route table, and a response recorder for
proxying requests through RPC.
All templates include MCP-ready doc comments and work with
--no-mcp. The default template (no flag) is unchanged.
Usage:
micro new myservice --template crud
micro new myservice --template pubsub
micro new myservice --template api
* fix(ai): update Atlas Cloud provider to use actual API formats
Fix the Atlas Cloud image generation to use their real async API:
POST /api/v1/model/generateImage → poll /api/v1/model/prediction/{id}
instead of the OpenAI-compatible endpoint which doesn't exist.
Add Quality and OutputFormat fields to ai.ImageRequest for
provider-specific image parameters.
Update default text model from llama-3.3-70b (doesn't exist) to
deepseek-ai/DeepSeek-V3-0324 (their flagship model). Update
default image model to openai/gpt-image-2/text-to-image.
* feat(website): add AI-generated images to landing page, docs, and blog
Generate 5 images via Atlas Cloud's image API (gpt-image-2) to
elevate the website experience:
- hero.png: microservices network graph for landing page
- architecture.png: registry + broker architecture diagram
- mcp-agent.png: AI agent calling services via MCP
- developer-experience.png: terminal showing micro run/chat
- blog-atlas.png: Atlas Cloud unified API illustration
Add visual sections to the landing page with architecture,
MCP integration, and developer experience showcases. Add
images to docs index, MCP docs, and Atlas Cloud blog post.
All images resized to 1200px wide and optimized for web.
Generated using Atlas Cloud sponsor credits.
* feat(website): redesign landing page and add images to docs
Redesign the landing page from a centered card layout to a
full-width modern site with:
- Top navigation bar
- Hero section with gradient background and CTA buttons
- Full-width image showcase sections
- Two-column layout for architecture, MCP, and DX sections
- Feature grid with 6 capabilities
- Footer with links
- Responsive breakpoints for mobile
Generate 3 more images via Atlas Cloud for docs:
- getting-started.png for the getting started guide
- deployment.png for the deployment guide
- data-model.png for the data model docs
Add images to getting-started.md, model.md, and deployment.md.
---------
Co-authored-by: Claude <noreply@anthropic.com>
|
||
|
|
86782e6d77 |
Add ImageModel interface and multi-turn conversation support (#2906)
* feat(ai): add ImageModel interface with Atlas Cloud and OpenAI support Add ai.ImageModel interface for text-to-image generation alongside the existing ai.Model for text. Uses the same options pattern (WithAPIKey, WithBaseURL) and the same provider registration system (RegisterImage/NewImage). Implement GenerateImage for Atlas Cloud and OpenAI providers via the OpenAI-compatible /v1/images/generations endpoint. Default image model is gpt-image-1. Responses return images as URL, base64, or both depending on the provider. Update Atlas Cloud blog post and integration guide with image generation examples. Update ai/README.md with ImageModel docs. * fix(website): widen docs content by reducing layout max-width to 1100px Remove the 800px max-width on .content (which left empty space on the right) and reduce the overall .layout and footer from 1400px to 1100px. With the 230px sidebar this gives ~830px of content width — readable and fills the page properly on desktop. * feat(ai): add History for multi-turn conversation state Add ai.History — a lightweight message accumulator that tracks user prompts, assistant replies, and tool call/result pairs across turns. FIFO truncation when message count exceeds the configured limit. System prompt is passed through on every Generate call. Wire History into micro chat so conversations are multi-turn by default (limit 50 messages). Add 'reset' command to clear history mid-session. 5 unit tests covering accumulation, truncation, reset, snapshot isolation, and tool call recording. --------- Co-authored-by: Claude <noreply@anthropic.com> |
||
|
|
1e2901ad0e |
feat(ai): add ImageModel interface with Atlas Cloud and OpenAI support (#2905)
Add ai.ImageModel interface for text-to-image generation alongside the existing ai.Model for text. Uses the same options pattern (WithAPIKey, WithBaseURL) and the same provider registration system (RegisterImage/NewImage). Implement GenerateImage for Atlas Cloud and OpenAI providers via the OpenAI-compatible /v1/images/generations endpoint. Default image model is gpt-image-1. Responses return images as URL, base64, or both depending on the provider. Update Atlas Cloud blog post and integration guide with image generation examples. Update ai/README.md with ImageModel docs. Co-authored-by: Claude <noreply@anthropic.com> |
||
|
|
426d7e4e6c |
fix: align sponsor logos with fixed height and clean SVG sources (#2903)
Use height="26" on both logos for consistent alignment. Switch Anthropic to the Wikimedia wordmark SVG (no padding) instead of the logo.wine version which had excessive whitespace. Co-authored-by: Claude <noreply@anthropic.com> |
||
|
|
5968fce2d6 |
docs: add Atlas Cloud sponsorship blog post and integration guide (#2902)
Add blog/8 announcing Atlas Cloud as an official Go Micro sponsor. Covers the sponsorship, Atlas Cloud's platform (300+ models, OpenAI compatibility, enterprise compliance), and how the integration works with the ai package, ai/tools, micro chat, and micro run. Add guides/atlascloud-integration.md with full setup instructions: quick start, configuration options, environment variables, model selection, tool calling with services, and provider swapping. Add Atlas Cloud and AI Provider guides to the docs sidebar navigation. Add sponsorship link to README header. Co-authored-by: Claude <noreply@anthropic.com> |
||
|
|
415b0a76c2 |
Fix README header formatting
Removed a redundant pipe character from the README header. |
||
|
|
7ef9a60441 |
Update README with documentation link and cleanup
Added documentation link to the README header and removed redundant documentation line. |
||
|
|
be156ecb95 |
Adjust logo width in README
Reduce the width of the Anthropic logo in sponsors section. |
||
|
|
713dabbb5a | Update Anthropic logo URL in README | ||
|
|
bbea48da78 |
Add sponsors section to README
Added sponsors section with Anthropic logo to README. |
||
|
|
a0ad9ee566 |
Claude/fix issue 2893 x3rpd (#2901)
* docs: add AI provider integration guide and Supported AI Providers section Add a step-by-step guide for AI infrastructure companies to implement ai.Model and contribute a provider to go-micro. Covers the full lifecycle: skeleton, tool call handling, tests, registration, and PR checklist. Add a "Supported AI Providers" section to the project README that lists current providers (Anthropic, OpenAI) in a table and links to the integration guide with a call-to-action for new providers and sponsors. Streamline the "Adding a New Provider" section in ai/README.md to point to the new guide instead of duplicating a full code listing. * fix: remove nonexistent Discord link from README * fix(website): set content container width to 800px on desktop Move the 800px max-width from .markdown-body up to .content so the entire content pane (not just the inner body) is sized correctly. The container now fills up to 800px beside the sidebar. * feat(ai): wire Atlas Cloud into server and auto-detection Import atlascloud provider in the micro server so it is available when running micro run / micro server. Add atlascloud to AutoDetectProvider so --ai_base_url with an atlascloud domain selects the right provider automatically. * feat(ai): add Google Gemini provider Add ai/gemini implementing ai.Model for Google's Gemini API. Uses the native generateContent endpoint with system_instruction, contents/parts, and functionDeclarations — not an OpenAI shim. Default model gemini-2.5-flash, auth via x-goog-api-key header. Wire into micro server imports and AutoDetectProvider (matches googleapis.com and google in base URL). Update README.md and ai/README.md with provider listing. * feat(ai): add Groq, Mistral, and Together AI providers Add three new OpenAI-compatible providers: - ai/groq: ultra-fast inference, default model llama-3.3-70b-versatile - ai/mistral: Mistral AI, default model mistral-large-latest - ai/together: Together AI, default model Llama-3.3-70B-Instruct-Turbo All three are wired into the micro server imports and AutoDetectProvider. README and ai/README updated with the full provider table. * feat(ai): add ai/tools helper and 'micro chat' interactive agent Extract the registry-discovery + RPC-execution loop from the web agent playground into a reusable ai/tools package: - tools.New(reg) creates a Set bound to a registry - Set.Discover() walks the registry and returns []ai.Tool with LLM-safe (underscored) names, remembering the mapping back to the original dotted form - Set.Handler(client) returns an ai.ToolHandler that resolves the safe name and issues the RPC Add cmd/micro/chat — an interactive 'micro chat' REPL that uses ai/tools to let users talk to their services through any registered AI provider. Supports --prompt for single-shot use, auto-detects the provider from --base_url, and falls back to the provider's conventional env var (ANTHROPIC_API_KEY, etc). Update README with the new command and the programmatic example. * feat(examples): add gRPC interop example Add examples/grpc-interop showing that any standard gRPC client can call a go-micro service — no go-micro SDK required on the client side. Includes: - proto/greeter.proto with generated Go, gRPC, and micro stubs - server/ using go-micro gRPC transport - client/ using stock google.golang.org/grpc (no go-micro imports) - README with Python example and explanation of how routing works Addresses the confusion from issue #2818 where users didn't know that go-micro gRPC services are callable by any gRPC client. * fix: strip /api prefix from MCP routes Change /api/mcp/tools and /api/mcp/call to /mcp/tools and /mcp/call. MCP is a first-class feature, not a sub-path of the API proxy. Update server routes, playground template, scopes template, run.go output, README, CLI README, and all docs. --------- Co-authored-by: Claude <noreply@anthropic.com> |
||
|
|
f5e33317b3 |
Remove Micro app platform promotion from README
Removed the promotion for the Micro app platform from the README. |
||
|
|
081e375f29 |
Add AI provider integration guide and new providers support (#2900)
* docs: add AI provider integration guide and Supported AI Providers section Add a step-by-step guide for AI infrastructure companies to implement ai.Model and contribute a provider to go-micro. Covers the full lifecycle: skeleton, tool call handling, tests, registration, and PR checklist. Add a "Supported AI Providers" section to the project README that lists current providers (Anthropic, OpenAI) in a table and links to the integration guide with a call-to-action for new providers and sponsors. Streamline the "Adding a New Provider" section in ai/README.md to point to the new guide instead of duplicating a full code listing. * fix: remove nonexistent Discord link from README * fix(website): set content container width to 800px on desktop Move the 800px max-width from .markdown-body up to .content so the entire content pane (not just the inner body) is sized correctly. The container now fills up to 800px beside the sidebar. * feat(ai): wire Atlas Cloud into server and auto-detection Import atlascloud provider in the micro server so it is available when running micro run / micro server. Add atlascloud to AutoDetectProvider so --ai_base_url with an atlascloud domain selects the right provider automatically. * feat(ai): add Google Gemini provider Add ai/gemini implementing ai.Model for Google's Gemini API. Uses the native generateContent endpoint with system_instruction, contents/parts, and functionDeclarations — not an OpenAI shim. Default model gemini-2.5-flash, auth via x-goog-api-key header. Wire into micro server imports and AutoDetectProvider (matches googleapis.com and google in base URL). Update README.md and ai/README.md with provider listing. * feat(ai): add Groq, Mistral, and Together AI providers Add three new OpenAI-compatible providers: - ai/groq: ultra-fast inference, default model llama-3.3-70b-versatile - ai/mistral: Mistral AI, default model mistral-large-latest - ai/together: Together AI, default model Llama-3.3-70B-Instruct-Turbo All three are wired into the micro server imports and AutoDetectProvider. README and ai/README updated with the full provider table. * feat(ai): add ai/tools helper and 'micro chat' interactive agent Extract the registry-discovery + RPC-execution loop from the web agent playground into a reusable ai/tools package: - tools.New(reg) creates a Set bound to a registry - Set.Discover() walks the registry and returns []ai.Tool with LLM-safe (underscored) names, remembering the mapping back to the original dotted form - Set.Handler(client) returns an ai.ToolHandler that resolves the safe name and issues the RPC Add cmd/micro/chat — an interactive 'micro chat' REPL that uses ai/tools to let users talk to their services through any registered AI provider. Supports --prompt for single-shot use, auto-detects the provider from --base_url, and falls back to the provider's conventional env var (ANTHROPIC_API_KEY, etc). Update README with the new command and the programmatic example. * feat(examples): add gRPC interop example Add examples/grpc-interop showing that any standard gRPC client can call a go-micro service — no go-micro SDK required on the client side. Includes: - proto/greeter.proto with generated Go, gRPC, and micro stubs - server/ using go-micro gRPC transport - client/ using stock google.golang.org/grpc (no go-micro imports) - README with Python example and explanation of how routing works Addresses the confusion from issue #2818 where users didn't know that go-micro gRPC services are callable by any gRPC client. --------- Co-authored-by: Claude <noreply@anthropic.com> |
||
|
|
2f78103fed |
Claude/fix issue 2893 x3rpd (#2899)
* docs: add AI provider integration guide and Supported AI Providers section Add a step-by-step guide for AI infrastructure companies to implement ai.Model and contribute a provider to go-micro. Covers the full lifecycle: skeleton, tool call handling, tests, registration, and PR checklist. Add a "Supported AI Providers" section to the project README that lists current providers (Anthropic, OpenAI) in a table and links to the integration guide with a call-to-action for new providers and sponsors. Streamline the "Adding a New Provider" section in ai/README.md to point to the new guide instead of duplicating a full code listing. * feat(ai): add Atlas Cloud provider Add ai/atlascloud implementing ai.Model for Atlas Cloud's OpenAI-compatible chat completions API. Registers as "atlascloud" with default model llama-3.3-70b and base URL https://api.atlascloud.ai. Supports tool calling via ToolHandler. Includes 7 unit tests covering registration, defaults, init, generate-without-key, and stream-not-implemented. Update the Supported AI Providers table in README.md and the Supported Providers section in ai/README.md. * fix: remove nonexistent Discord link from README * fix(website): remove Micro app banner and widen content to 800px Remove the "Try Micro" promotional banner from the homepage. Set the docs content max-width to 800px for better readability on desktop. --------- Co-authored-by: Claude <noreply@anthropic.com> |
||
|
|
60527e1fe8 |
Add AI provider integration guide and Atlas Cloud support (#2898)
* docs: add AI provider integration guide and Supported AI Providers section Add a step-by-step guide for AI infrastructure companies to implement ai.Model and contribute a provider to go-micro. Covers the full lifecycle: skeleton, tool call handling, tests, registration, and PR checklist. Add a "Supported AI Providers" section to the project README that lists current providers (Anthropic, OpenAI) in a table and links to the integration guide with a call-to-action for new providers and sponsors. Streamline the "Adding a New Provider" section in ai/README.md to point to the new guide instead of duplicating a full code listing. * feat(ai): add Atlas Cloud provider Add ai/atlascloud implementing ai.Model for Atlas Cloud's OpenAI-compatible chat completions API. Registers as "atlascloud" with default model llama-3.3-70b and base URL https://api.atlascloud.ai. Supports tool calling via ToolHandler. Includes 7 unit tests covering registration, defaults, init, generate-without-key, and stream-not-implemented. Update the Supported AI Providers table in README.md and the Supported Providers section in ai/README.md. * fix: remove nonexistent Discord link from README --------- Co-authored-by: Claude <noreply@anthropic.com> |
||
|
|
defb2786ef |
update AI provider documentation (#2897)
* feat: add prometheus monitoring wrapper Reintroduces the Prometheus metrics wrapper previously available in the plugins repository, updated for go-micro v5. Exposes request count and latency histograms for handlers, subscribers, and outgoing client calls via NewHandlerWrapper, NewSubscriberWrapper, NewCallWrapper and NewClientWrapper, labelled with service/endpoint/status. Options cover namespace, subsystem, const labels, histogram buckets and a custom registerer; duplicate collectors (e.g. from multiple wrappers sharing the same config) are reused transparently via a cached metrics bundle. Fixes #2893 * fix(registry/etcd): clear lease/register caches on KeepAlive channel closure When the etcd client's long-lived KeepAlive channel closes (e.g. because the lease expired on the server side during a network partition), the previous cleanup only removed the channel bookkeeping. The stale entries in `leases` and `register` caused the next registerNode() heartbeat to hit the "unchanged hash" short-circuit and skip re-registration entirely, so the service permanently disappeared from etcd. Extract the cleanup into handleKeepAliveClosed and also drop the cached lease id and hash so the next heartbeat performs a full Grant+Put and the service recovers within one RegisterInterval. Regression introduced by #2822; fix is symmetric with the existing synchronous KeepAliveOnce recovery path that propagates rpctypes.ErrLeaseNotFound. * docs: add AI provider integration guide and Supported AI Providers section Add a step-by-step guide for AI infrastructure companies to implement ai.Model and contribute a provider to go-micro. Covers the full lifecycle: skeleton, tool call handling, tests, registration, and PR checklist. Add a "Supported AI Providers" section to the project README that lists current providers (Anthropic, OpenAI) in a table and links to the integration guide with a call-to-action for new providers and sponsors. Streamline the "Adding a New Provider" section in ai/README.md to point to the new guide instead of duplicating a full code listing. * Update contribution guidelines in README.md Removed Discord contact information for platform contributions. --------- Co-authored-by: Claude <noreply@anthropic.com> |
||
|
|
15cc876848 | Emphasize 'Micro' in README link | ||
|
|
d3cfb3a99a | Update app platform name from 'Mu' to 'Micro' | ||
|
|
b1680ca2da | Update app platform link from Mu.xyz to Micro | ||
|
|
90f7617fac |
Claude/fix issue 2893 x3rpd (#2895)
* feat: add prometheus monitoring wrapper Reintroduces the Prometheus metrics wrapper previously available in the plugins repository, updated for go-micro v5. Exposes request count and latency histograms for handlers, subscribers, and outgoing client calls via NewHandlerWrapper, NewSubscriberWrapper, NewCallWrapper and NewClientWrapper, labelled with service/endpoint/status. Options cover namespace, subsystem, const labels, histogram buckets and a custom registerer; duplicate collectors (e.g. from multiple wrappers sharing the same config) are reused transparently via a cached metrics bundle. Fixes #2893 * fix(registry/etcd): clear lease/register caches on KeepAlive channel closure When the etcd client's long-lived KeepAlive channel closes (e.g. because the lease expired on the server side during a network partition), the previous cleanup only removed the channel bookkeeping. The stale entries in `leases` and `register` caused the next registerNode() heartbeat to hit the "unchanged hash" short-circuit and skip re-registration entirely, so the service permanently disappeared from etcd. Extract the cleanup into handleKeepAliveClosed and also drop the cached lease id and hash so the next heartbeat performs a full Grant+Put and the service recovers within one RegisterInterval. Regression introduced by #2822; fix is symmetric with the existing synchronous KeepAliveOnce recovery path that propagates rpctypes.ErrLeaseNotFound. --------- Co-authored-by: Claude <noreply@anthropic.com> |
||
|
|
79722e0c27 |
feat: add prometheus monitoring wrapper (#2894)
Reintroduces the Prometheus metrics wrapper previously available in the plugins repository, updated for go-micro v5. Exposes request count and latency histograms for handlers, subscribers, and outgoing client calls via NewHandlerWrapper, NewSubscriberWrapper, NewCallWrapper and NewClientWrapper, labelled with service/endpoint/status. Options cover namespace, subsystem, const labels, histogram buckets and a custom registerer; duplicate collectors (e.g. from multiple wrappers sharing the same config) are reused transparently via a cached metrics bundle. Fixes #2893 Co-authored-by: Claude <noreply@anthropic.com> |
||
|
|
03f4759474 | Fix inline style attribute in index.html | ||
|
|
f6fb541ace |
Enhance Mu.xyz promotion with styled div
Updated the promotional text for Mu.xyz with enhanced styling. |
||
|
|
1426c8f349 | Update README to use emoji for Mu.xyz link | ||
|
|
5aedb601ba |
Add Mu.xyz promotional link to README
Added a promotional link for Mu.xyz app platform. |
||
|
|
bd13975acf |
Update container width and add promotional text
Increased the maximum width of the container and added a promotional paragraph for Mu.xyz. |
||
|
|
213a09276e | Update default.html | ||
|
|
f4291957e8 |
Remove Blog link from index.html
Removed the Blog link from the website index. |
||
|
|
07411b1ef6 |
Remove article on chat app from blog index
Removed an article about building a chat app from the blog. |
||
|
|
544496eec6 | Delete internal/website/blog/8.md | ||
|
|
2e95c4c610 |
Remove showcase section from index.html
Removed the showcase section for Go Micro projects. |
||
|
|
d96f12f57b |
Claude/update docs roadmap f zd2 j (#2889)
* feat: add agent platform showcase and blog post Add a complete platform example (Users, Posts, Comments, Mail) that mirrors micro/blog, demonstrating how existing microservices become AI-accessible through MCP with zero code changes. Includes blog post "Your Microservices Are Already an AI Platform" walking through real agent workflows: signup, content creation, commenting, tagging, and cross-service messaging. https://claude.ai/code/session_01GkduEhcrqcG45rdfYh8dAc * refactor: rename handler types to drop redundant Service suffix UserService → Users, PostService → Posts, CommentService → Comments, MailService → Mail. Matches micro/blog naming convention. https://claude.ai/code/session_01GkduEhcrqcG45rdfYh8dAc * refactor: consolidate top-level directories, reduce framework bloat Move internal/non-public packages behind internal/ or into their parent packages where they belong: - deploy/ → gateway/mcp/deploy/ (Helm charts belong with the gateway) - profile/ → service/profile/ (preset plugin profiles are a service concern) - scripts/ → internal/scripts/ (install script is not public API) - test/ → internal/test/ (test harness is not public API) - util/ → internal/util/ (internal helpers shouldn't be imported externally) Also fixes CLAUDE.md merge conflict markers and updates project structure documentation. All import paths updated. Build and tests pass. https://claude.ai/code/session_01GkduEhcrqcG45rdfYh8dAc * refactor: redesign model package to match framework conventions Rename model.Database interface to model.Model (consistent with client.Client, server.Server, store.Store). Remove generics in favor of interface{}-based API with reflection. Key changes: - model.Model interface: Register once, CRUD infers table from type - DefaultModel + NewModel() + package-level convenience functions - Schema registered via Register(&User{}), no per-call schema passing - Memory implementation as default (in model package, like store) - memory/sqlite/postgres backends updated for new interface - protoc-gen-micro generates RegisterXModel() instead of generic factory - All docs, blog, and README updated https://claude.ai/code/session_01GkduEhcrqcG45rdfYh8dAc * docs: clarify blog post 7 uses modular monolith, not multi-service Blog post 7 demonstrated all handlers in a single process but framed it as microservices without acknowledging the architectural difference. - Add "A Note on Architecture" section explaining this is a modular monolith demo and pointing to micro/blog for multi-service - Clarify that handlers can be broken out into separate services later - Fix "service registry" language to match single-process reality - Restructure "Adding MCP to Existing Services" to distinguish the in-process approach from registry-based gateway options - Update closing to acknowledge both paradigms - Fix README type names (&CommentService{} -> &Comments{}, etc.) https://claude.ai/code/session_01GkduEhcrqcG45rdfYh8dAc * docs: add Micro Chat to website showcase https://claude.ai/code/session_01GkduEhcrqcG45rdfYh8dAc * feat: github artifact release CI (#2886) * 👷feat(ci): add artifact and docker releases * 💚fix(ci): build issues * 💚fix(ci): add permissions * 💚fix(ci): multiple artifacts * 💚fix(ci): split archives * 💚fix(ci): cross platform list * 🚧chore(ci): package name * 🐛fix(script): install script extract arch * 👷fix(ci): docker origin go-micro * Update image reference in goreleaser configuration (#2887) Fix wrong order `user/repo` * Add blog post on building a chat app with Go Micro Added a blog post detailing the development of a full chat app using Go Micro, outlining features, architecture, and lessons learned. * docs: add blog post 8 to index, put Blog before Docs on homepage - Add "We Built a Full Chat App in a Day" (blog/8) to blog index - Reorder homepage links: Blog first (primary), Docs second - Rename "Documentation" to "Docs" https://claude.ai/code/session_01GkduEhcrqcG45rdfYh8dAc --------- Co-authored-by: Claude <noreply@anthropic.com> Co-authored-by: Alexander Serheyev <74361701+alex-dna-tech@users.noreply.github.com> |
||
|
|
8608c15fbb |
Add blog post on building a chat app with Go Micro
Added a blog post detailing the development of a full chat app using Go Micro, outlining features, architecture, and lessons learned. |
||
|
|
9823f6df5c |
Add platform showcase, blog post, and refactor project structure (#2888)
* feat: add agent platform showcase and blog post Add a complete platform example (Users, Posts, Comments, Mail) that mirrors micro/blog, demonstrating how existing microservices become AI-accessible through MCP with zero code changes. Includes blog post "Your Microservices Are Already an AI Platform" walking through real agent workflows: signup, content creation, commenting, tagging, and cross-service messaging. https://claude.ai/code/session_01GkduEhcrqcG45rdfYh8dAc * refactor: rename handler types to drop redundant Service suffix UserService → Users, PostService → Posts, CommentService → Comments, MailService → Mail. Matches micro/blog naming convention. https://claude.ai/code/session_01GkduEhcrqcG45rdfYh8dAc * refactor: consolidate top-level directories, reduce framework bloat Move internal/non-public packages behind internal/ or into their parent packages where they belong: - deploy/ → gateway/mcp/deploy/ (Helm charts belong with the gateway) - profile/ → service/profile/ (preset plugin profiles are a service concern) - scripts/ → internal/scripts/ (install script is not public API) - test/ → internal/test/ (test harness is not public API) - util/ → internal/util/ (internal helpers shouldn't be imported externally) Also fixes CLAUDE.md merge conflict markers and updates project structure documentation. All import paths updated. Build and tests pass. https://claude.ai/code/session_01GkduEhcrqcG45rdfYh8dAc * refactor: redesign model package to match framework conventions Rename model.Database interface to model.Model (consistent with client.Client, server.Server, store.Store). Remove generics in favor of interface{}-based API with reflection. Key changes: - model.Model interface: Register once, CRUD infers table from type - DefaultModel + NewModel() + package-level convenience functions - Schema registered via Register(&User{}), no per-call schema passing - Memory implementation as default (in model package, like store) - memory/sqlite/postgres backends updated for new interface - protoc-gen-micro generates RegisterXModel() instead of generic factory - All docs, blog, and README updated https://claude.ai/code/session_01GkduEhcrqcG45rdfYh8dAc * docs: clarify blog post 7 uses modular monolith, not multi-service Blog post 7 demonstrated all handlers in a single process but framed it as microservices without acknowledging the architectural difference. - Add "A Note on Architecture" section explaining this is a modular monolith demo and pointing to micro/blog for multi-service - Clarify that handlers can be broken out into separate services later - Fix "service registry" language to match single-process reality - Restructure "Adding MCP to Existing Services" to distinguish the in-process approach from registry-based gateway options - Update closing to acknowledge both paradigms - Fix README type names (&CommentService{} -> &Comments{}, etc.) https://claude.ai/code/session_01GkduEhcrqcG45rdfYh8dAc * docs: add Micro Chat to website showcase https://claude.ai/code/session_01GkduEhcrqcG45rdfYh8dAc --------- Co-authored-by: Claude <noreply@anthropic.com> |
||
|
|
7a5d86a2a4 |
Claude/update docs roadmap f zd2 j (#2885)
* feat: add agent platform showcase and blog post Add a complete platform example (Users, Posts, Comments, Mail) that mirrors micro/blog, demonstrating how existing microservices become AI-accessible through MCP with zero code changes. Includes blog post "Your Microservices Are Already an AI Platform" walking through real agent workflows: signup, content creation, commenting, tagging, and cross-service messaging. https://claude.ai/code/session_01GkduEhcrqcG45rdfYh8dAc * refactor: rename handler types to drop redundant Service suffix UserService → Users, PostService → Posts, CommentService → Comments, MailService → Mail. Matches micro/blog naming convention. https://claude.ai/code/session_01GkduEhcrqcG45rdfYh8dAc * refactor: consolidate top-level directories, reduce framework bloat Move internal/non-public packages behind internal/ or into their parent packages where they belong: - deploy/ → gateway/mcp/deploy/ (Helm charts belong with the gateway) - profile/ → service/profile/ (preset plugin profiles are a service concern) - scripts/ → internal/scripts/ (install script is not public API) - test/ → internal/test/ (test harness is not public API) - util/ → internal/util/ (internal helpers shouldn't be imported externally) Also fixes CLAUDE.md merge conflict markers and updates project structure documentation. All import paths updated. Build and tests pass. https://claude.ai/code/session_01GkduEhcrqcG45rdfYh8dAc * refactor: redesign model package to match framework conventions Rename model.Database interface to model.Model (consistent with client.Client, server.Server, store.Store). Remove generics in favor of interface{}-based API with reflection. Key changes: - model.Model interface: Register once, CRUD infers table from type - DefaultModel + NewModel() + package-level convenience functions - Schema registered via Register(&User{}), no per-call schema passing - Memory implementation as default (in model package, like store) - memory/sqlite/postgres backends updated for new interface - protoc-gen-micro generates RegisterXModel() instead of generic factory - All docs, blog, and README updated https://claude.ai/code/session_01GkduEhcrqcG45rdfYh8dAc * docs: clarify blog post 7 uses modular monolith, not multi-service Blog post 7 demonstrated all handlers in a single process but framed it as microservices without acknowledging the architectural difference. - Add "A Note on Architecture" section explaining this is a modular monolith demo and pointing to micro/blog for multi-service - Clarify that handlers can be broken out into separate services later - Fix "service registry" language to match single-process reality - Restructure "Adding MCP to Existing Services" to distinguish the in-process approach from registry-based gateway options - Update closing to acknowledge both paradigms - Fix README type names (&CommentService{} -> &Comments{}, etc.) https://claude.ai/code/session_01GkduEhcrqcG45rdfYh8dAc --------- Co-authored-by: Claude <noreply@anthropic.com> |
||
|
|
8ecdf07e6b | Update description of the blogging platform example | ||
|
|
1bb25d6e7f |
Add agent platform showcase and refactor project structure (#2884)
* feat: add agent platform showcase and blog post Add a complete platform example (Users, Posts, Comments, Mail) that mirrors micro/blog, demonstrating how existing microservices become AI-accessible through MCP with zero code changes. Includes blog post "Your Microservices Are Already an AI Platform" walking through real agent workflows: signup, content creation, commenting, tagging, and cross-service messaging. https://claude.ai/code/session_01GkduEhcrqcG45rdfYh8dAc * refactor: rename handler types to drop redundant Service suffix UserService → Users, PostService → Posts, CommentService → Comments, MailService → Mail. Matches micro/blog naming convention. https://claude.ai/code/session_01GkduEhcrqcG45rdfYh8dAc * refactor: consolidate top-level directories, reduce framework bloat Move internal/non-public packages behind internal/ or into their parent packages where they belong: - deploy/ → gateway/mcp/deploy/ (Helm charts belong with the gateway) - profile/ → service/profile/ (preset plugin profiles are a service concern) - scripts/ → internal/scripts/ (install script is not public API) - test/ → internal/test/ (test harness is not public API) - util/ → internal/util/ (internal helpers shouldn't be imported externally) Also fixes CLAUDE.md merge conflict markers and updates project structure documentation. All import paths updated. Build and tests pass. https://claude.ai/code/session_01GkduEhcrqcG45rdfYh8dAc * refactor: redesign model package to match framework conventions Rename model.Database interface to model.Model (consistent with client.Client, server.Server, store.Store). Remove generics in favor of interface{}-based API with reflection. Key changes: - model.Model interface: Register once, CRUD infers table from type - DefaultModel + NewModel() + package-level convenience functions - Schema registered via Register(&User{}), no per-call schema passing - Memory implementation as default (in model package, like store) - memory/sqlite/postgres backends updated for new interface - protoc-gen-micro generates RegisterXModel() instead of generic factory - All docs, blog, and README updated https://claude.ai/code/session_01GkduEhcrqcG45rdfYh8dAc --------- Co-authored-by: Claude <noreply@anthropic.com> |
||
|
|
b8fc0902d7 |
Claude/update docs roadmap f zd2 j (#2883)
* feat: add agent platform showcase and blog post Add a complete platform example (Users, Posts, Comments, Mail) that mirrors micro/blog, demonstrating how existing microservices become AI-accessible through MCP with zero code changes. Includes blog post "Your Microservices Are Already an AI Platform" walking through real agent workflows: signup, content creation, commenting, tagging, and cross-service messaging. https://claude.ai/code/session_01GkduEhcrqcG45rdfYh8dAc * refactor: rename handler types to drop redundant Service suffix UserService → Users, PostService → Posts, CommentService → Comments, MailService → Mail. Matches micro/blog naming convention. https://claude.ai/code/session_01GkduEhcrqcG45rdfYh8dAc --------- Co-authored-by: Claude <noreply@anthropic.com> |
||
|
|
524e16296b |
Update documentation, add agent demo, and enhance service API (#2882)
* docs: update all four documentation guides and mark Q2 complete - ai-native-services: add WithMCP one-liner, standalone gateway, WebSocket client example, and OpenTelemetry observability section - mcp-security: add OTel distributed tracing, WebSocket authentication (connection-level and per-message), DeniedReason audit field - tool-descriptions: add manual overrides with WithEndpointDocs and export formats section - agent-patterns: add LangChain/LlamaIndex SDK pattern and standalone gateway production pattern with Docker example - Update roadmap: mark Q2 documentation as complete, Q2 at 100% - Update status: reflect all recent completions, shift priorities https://claude.ai/code/session_01GkduEhcrqcG45rdfYh8dAc * feat: add agent demo example and blog post Add examples/agent-demo with a multi-service project management app (projects, tasks, team) that demonstrates AI agents interacting with Go Micro services through MCP. Includes seed data and example prompts. Add blog post 4 "Agents Meet Microservices: A Hands-On Demo" walking through the example code and showing cross-service agent workflows. https://claude.ai/code/session_01GkduEhcrqcG45rdfYh8dAc * feat: enable multiple services in a single binary Remove global state mutations from service and cmd option functions so that configuring one service no longer overwrites another's settings. Key changes: - service/options.go: remove all DefaultXxx global writes from option functions; newOptions() now creates fresh Server, Client, Store, and Cache per service while sharing Registry, Broker, and Transport - cmd/cmd.go: newCmd() uses local copies instead of pointers to package globals; Before() no longer mutates DefaultXxx vars - cmd/options.go: remove global mutations from all option functions - service/service.go: export ServiceImpl type for cross-package use - service/group.go: new Group type for multi-service lifecycle - micro.go: add Start/Stop to Service interface, expose Group and NewGroup convenience function - examples/multi-service: working example with two services https://claude.ai/code/session_01GkduEhcrqcG45rdfYh8dAc * docs: highlight multi-service binary support Add multi-service section to README with code example, update features list, add to examples index, and note in status summary. https://claude.ai/code/session_01GkduEhcrqcG45rdfYh8dAc * feat: unify service API and clean up developer experience - Unified service creation: micro.New("name", opts...) as canonical API - Clean handler registration: service.Handle(handler, opts...) accepts server.HandlerOption args directly, no need to reach through Server() - Unexported serviceImpl: users interact through Service interface only - Service groups use Service interface (not concrete type) - Fixed Stop() to properly propagate BeforeStop/AfterStop errors - Fixed store init: error-level log instead of fatal on init failure - Updated all examples to use consistent patterns - Updated README, getting-started, MCP docs, and guides - Added blog post about the DX cleanup https://claude.ai/code/session_01GkduEhcrqcG45rdfYh8dAc * fix: add blog post 5 to blog index Blog post 5 (Developer Experience Cleanup) existed as a file but was missing from the blog index page. https://claude.ai/code/session_01GkduEhcrqcG45rdfYh8dAc * feat: make micro new generate MCP-enabled services by default - main.go template includes mcp.WithMCP(":3001") by default - Handler template has agent-friendly doc comments with @example tags - Proto template has descriptive field comments - README includes MCP usage, Claude Code config, and tool description tips - Makefile adds mcp-tools, mcp-test, mcp-serve targets - go.mod updated to Go 1.22 - Added --no-mcp flag to opt out of MCP integration - Post-create output shows MCP endpoint URLs https://claude.ai/code/session_01GkduEhcrqcG45rdfYh8dAc * docs: add MCP migration guide and troubleshooting guide - Migration guide: 3 approaches to add MCP to existing services (WithMCP one-liner, standalone gateway, CLI) - Troubleshooting guide: common issues with agents, WebSocket, Claude Code, auth, rate limiting, and performance https://claude.ai/code/session_01GkduEhcrqcG45rdfYh8dAc * refactor: rename model/ package to ai/ for AI model providers The model/ package name conflicted with the conventional use of "model" for data models. Renamed to ai/ which better describes the package's purpose (AI provider abstraction for Anthropic, OpenAI, etc.) and frees up model/ for future data model layer use. - Rename model/ → ai/ with package name change - Update all Go imports from go-micro.dev/v5/model to go-micro.dev/v5/ai - Update cmd/micro/server/server.go references (model.X → ai.X) - Update all documentation and roadmap references - All tests pass, CLI builds successfully https://claude.ai/code/session_01GkduEhcrqcG45rdfYh8dAc * feat: add model package for typed data access with CRUD and queries New model/ package provides a typed data model layer using Go generics. Supports structured CRUD operations, WHERE filters, ordering, pagination, and automatic schema creation from struct tags. Three backends: - memory: in-memory for development and testing - sqlite: embedded SQL for dev and single-node production - postgres: full PostgreSQL for production deployments Key features: - Generic Model[T] with Create/Read/Update/Delete/List/Count - Query builder: Where(), WhereOp(), OrderAsc/Desc(), Limit(), Offset() - Struct tags: model:"key" for primary key, model:"index" for indexes - Auto table creation from struct schema - 19 tests passing across memory and sqlite backends https://claude.ai/code/session_01GkduEhcrqcG45rdfYh8dAc * feat: add model code generation to protoc-gen-micro Extend the micro plugin to generate model structs from proto messages annotated with // @model. Generated alongside client/server code in the same .pb.micro.go file. For a proto message like: // @model message User { string id = 1; string name = 2; } Generates: - UserModel struct with model:"key" and json tags - NewUserModel(db) factory returning *model.Model[UserModel] - UserModelFromProto(*User) *UserModel converter - (*UserModel).ToProto() *User converter Supports @model(table=custom_table, key=custom_field) options. Adds GetComments() to generator for plugin comment inspection. https://claude.ai/code/session_01GkduEhcrqcG45rdfYh8dAc * feat: add Model() to Service interface for Client/Server/Model trifecta Every service now exposes Client(), Server(), and Model() — call services, handle requests, and save/query data from the same interface. Includes README docs, blog post, and a full model guide on the docs site. https://claude.ai/code/session_01GkduEhcrqcG45rdfYh8dAc * feat: add Helm chart for MCP gateway Kubernetes deployment Adds official Helm chart at deploy/helm/mcp-gateway/ with: - Deployment, Service, ServiceAccount templates - HPA for auto-scaling based on CPU/memory - Ingress with TLS support - Configurable registry (consul, etcd, mdns), rate limiting, JWT auth, audit logging, and per-tool scopes - Security context (non-root, read-only rootfs, drop all caps) - NOTES.txt with post-install connection instructions Updates roadmap and status docs to reflect Helm Charts as delivered. https://claude.ai/code/session_01GkduEhcrqcG45rdfYh8dAc * docs: add Helm chart entry to changelog https://claude.ai/code/session_01GkduEhcrqcG45rdfYh8dAc * feat: add per-tool circuit breakers to MCP gateway Protects downstream services from cascading failures. When a tool's RPC calls fail repeatedly, the circuit opens and rejects requests immediately until the service recovers (half-open probe pattern). - CircuitBreakerConfig with MaxFailures, Timeout, MaxHalfOpen - Per-tool breakers created during service discovery - Integrated into HTTP call path with 503 response when open - Records success/failure after each RPC call - --circuit-breaker and --circuit-breaker-timeout CLI flags - 8 unit tests covering all state transitions https://claude.ai/code/session_01GkduEhcrqcG45rdfYh8dAc --------- Co-authored-by: Claude <noreply@anthropic.com> |
||
|
|
d91812b476 |
Update documentation and add multi-service support with examples (#2881)
* docs: update all four documentation guides and mark Q2 complete - ai-native-services: add WithMCP one-liner, standalone gateway, WebSocket client example, and OpenTelemetry observability section - mcp-security: add OTel distributed tracing, WebSocket authentication (connection-level and per-message), DeniedReason audit field - tool-descriptions: add manual overrides with WithEndpointDocs and export formats section - agent-patterns: add LangChain/LlamaIndex SDK pattern and standalone gateway production pattern with Docker example - Update roadmap: mark Q2 documentation as complete, Q2 at 100% - Update status: reflect all recent completions, shift priorities https://claude.ai/code/session_01GkduEhcrqcG45rdfYh8dAc * feat: add agent demo example and blog post Add examples/agent-demo with a multi-service project management app (projects, tasks, team) that demonstrates AI agents interacting with Go Micro services through MCP. Includes seed data and example prompts. Add blog post 4 "Agents Meet Microservices: A Hands-On Demo" walking through the example code and showing cross-service agent workflows. https://claude.ai/code/session_01GkduEhcrqcG45rdfYh8dAc * feat: enable multiple services in a single binary Remove global state mutations from service and cmd option functions so that configuring one service no longer overwrites another's settings. Key changes: - service/options.go: remove all DefaultXxx global writes from option functions; newOptions() now creates fresh Server, Client, Store, and Cache per service while sharing Registry, Broker, and Transport - cmd/cmd.go: newCmd() uses local copies instead of pointers to package globals; Before() no longer mutates DefaultXxx vars - cmd/options.go: remove global mutations from all option functions - service/service.go: export ServiceImpl type for cross-package use - service/group.go: new Group type for multi-service lifecycle - micro.go: add Start/Stop to Service interface, expose Group and NewGroup convenience function - examples/multi-service: working example with two services https://claude.ai/code/session_01GkduEhcrqcG45rdfYh8dAc * docs: highlight multi-service binary support Add multi-service section to README with code example, update features list, add to examples index, and note in status summary. https://claude.ai/code/session_01GkduEhcrqcG45rdfYh8dAc * feat: unify service API and clean up developer experience - Unified service creation: micro.New("name", opts...) as canonical API - Clean handler registration: service.Handle(handler, opts...) accepts server.HandlerOption args directly, no need to reach through Server() - Unexported serviceImpl: users interact through Service interface only - Service groups use Service interface (not concrete type) - Fixed Stop() to properly propagate BeforeStop/AfterStop errors - Fixed store init: error-level log instead of fatal on init failure - Updated all examples to use consistent patterns - Updated README, getting-started, MCP docs, and guides - Added blog post about the DX cleanup https://claude.ai/code/session_01GkduEhcrqcG45rdfYh8dAc * fix: add blog post 5 to blog index Blog post 5 (Developer Experience Cleanup) existed as a file but was missing from the blog index page. https://claude.ai/code/session_01GkduEhcrqcG45rdfYh8dAc * feat: make micro new generate MCP-enabled services by default - main.go template includes mcp.WithMCP(":3001") by default - Handler template has agent-friendly doc comments with @example tags - Proto template has descriptive field comments - README includes MCP usage, Claude Code config, and tool description tips - Makefile adds mcp-tools, mcp-test, mcp-serve targets - go.mod updated to Go 1.22 - Added --no-mcp flag to opt out of MCP integration - Post-create output shows MCP endpoint URLs https://claude.ai/code/session_01GkduEhcrqcG45rdfYh8dAc * docs: add MCP migration guide and troubleshooting guide - Migration guide: 3 approaches to add MCP to existing services (WithMCP one-liner, standalone gateway, CLI) - Troubleshooting guide: common issues with agents, WebSocket, Claude Code, auth, rate limiting, and performance https://claude.ai/code/session_01GkduEhcrqcG45rdfYh8dAc * refactor: rename model/ package to ai/ for AI model providers The model/ package name conflicted with the conventional use of "model" for data models. Renamed to ai/ which better describes the package's purpose (AI provider abstraction for Anthropic, OpenAI, etc.) and frees up model/ for future data model layer use. - Rename model/ → ai/ with package name change - Update all Go imports from go-micro.dev/v5/model to go-micro.dev/v5/ai - Update cmd/micro/server/server.go references (model.X → ai.X) - Update all documentation and roadmap references - All tests pass, CLI builds successfully https://claude.ai/code/session_01GkduEhcrqcG45rdfYh8dAc * feat: add model package for typed data access with CRUD and queries New model/ package provides a typed data model layer using Go generics. Supports structured CRUD operations, WHERE filters, ordering, pagination, and automatic schema creation from struct tags. Three backends: - memory: in-memory for development and testing - sqlite: embedded SQL for dev and single-node production - postgres: full PostgreSQL for production deployments Key features: - Generic Model[T] with Create/Read/Update/Delete/List/Count - Query builder: Where(), WhereOp(), OrderAsc/Desc(), Limit(), Offset() - Struct tags: model:"key" for primary key, model:"index" for indexes - Auto table creation from struct schema - 19 tests passing across memory and sqlite backends https://claude.ai/code/session_01GkduEhcrqcG45rdfYh8dAc * feat: add model code generation to protoc-gen-micro Extend the micro plugin to generate model structs from proto messages annotated with // @model. Generated alongside client/server code in the same .pb.micro.go file. For a proto message like: // @model message User { string id = 1; string name = 2; } Generates: - UserModel struct with model:"key" and json tags - NewUserModel(db) factory returning *model.Model[UserModel] - UserModelFromProto(*User) *UserModel converter - (*UserModel).ToProto() *User converter Supports @model(table=custom_table, key=custom_field) options. Adds GetComments() to generator for plugin comment inspection. https://claude.ai/code/session_01GkduEhcrqcG45rdfYh8dAc * feat: add Model() to Service interface for Client/Server/Model trifecta Every service now exposes Client(), Server(), and Model() — call services, handle requests, and save/query data from the same interface. Includes README docs, blog post, and a full model guide on the docs site. https://claude.ai/code/session_01GkduEhcrqcG45rdfYh8dAc * feat: add Helm chart for MCP gateway Kubernetes deployment Adds official Helm chart at deploy/helm/mcp-gateway/ with: - Deployment, Service, ServiceAccount templates - HPA for auto-scaling based on CPU/memory - Ingress with TLS support - Configurable registry (consul, etcd, mdns), rate limiting, JWT auth, audit logging, and per-tool scopes - Security context (non-root, read-only rootfs, drop all caps) - NOTES.txt with post-install connection instructions Updates roadmap and status docs to reflect Helm Charts as delivered. https://claude.ai/code/session_01GkduEhcrqcG45rdfYh8dAc --------- Co-authored-by: Claude <noreply@anthropic.com> |
||
|
|
76bfeae456 |
Claude/update docs roadmap f zd2 j (#2880)
* docs: update all four documentation guides and mark Q2 complete - ai-native-services: add WithMCP one-liner, standalone gateway, WebSocket client example, and OpenTelemetry observability section - mcp-security: add OTel distributed tracing, WebSocket authentication (connection-level and per-message), DeniedReason audit field - tool-descriptions: add manual overrides with WithEndpointDocs and export formats section - agent-patterns: add LangChain/LlamaIndex SDK pattern and standalone gateway production pattern with Docker example - Update roadmap: mark Q2 documentation as complete, Q2 at 100% - Update status: reflect all recent completions, shift priorities https://claude.ai/code/session_01GkduEhcrqcG45rdfYh8dAc * feat: add agent demo example and blog post Add examples/agent-demo with a multi-service project management app (projects, tasks, team) that demonstrates AI agents interacting with Go Micro services through MCP. Includes seed data and example prompts. Add blog post 4 "Agents Meet Microservices: A Hands-On Demo" walking through the example code and showing cross-service agent workflows. https://claude.ai/code/session_01GkduEhcrqcG45rdfYh8dAc * feat: enable multiple services in a single binary Remove global state mutations from service and cmd option functions so that configuring one service no longer overwrites another's settings. Key changes: - service/options.go: remove all DefaultXxx global writes from option functions; newOptions() now creates fresh Server, Client, Store, and Cache per service while sharing Registry, Broker, and Transport - cmd/cmd.go: newCmd() uses local copies instead of pointers to package globals; Before() no longer mutates DefaultXxx vars - cmd/options.go: remove global mutations from all option functions - service/service.go: export ServiceImpl type for cross-package use - service/group.go: new Group type for multi-service lifecycle - micro.go: add Start/Stop to Service interface, expose Group and NewGroup convenience function - examples/multi-service: working example with two services https://claude.ai/code/session_01GkduEhcrqcG45rdfYh8dAc * docs: highlight multi-service binary support Add multi-service section to README with code example, update features list, add to examples index, and note in status summary. https://claude.ai/code/session_01GkduEhcrqcG45rdfYh8dAc * feat: unify service API and clean up developer experience - Unified service creation: micro.New("name", opts...) as canonical API - Clean handler registration: service.Handle(handler, opts...) accepts server.HandlerOption args directly, no need to reach through Server() - Unexported serviceImpl: users interact through Service interface only - Service groups use Service interface (not concrete type) - Fixed Stop() to properly propagate BeforeStop/AfterStop errors - Fixed store init: error-level log instead of fatal on init failure - Updated all examples to use consistent patterns - Updated README, getting-started, MCP docs, and guides - Added blog post about the DX cleanup https://claude.ai/code/session_01GkduEhcrqcG45rdfYh8dAc * fix: add blog post 5 to blog index Blog post 5 (Developer Experience Cleanup) existed as a file but was missing from the blog index page. https://claude.ai/code/session_01GkduEhcrqcG45rdfYh8dAc * feat: make micro new generate MCP-enabled services by default - main.go template includes mcp.WithMCP(":3001") by default - Handler template has agent-friendly doc comments with @example tags - Proto template has descriptive field comments - README includes MCP usage, Claude Code config, and tool description tips - Makefile adds mcp-tools, mcp-test, mcp-serve targets - go.mod updated to Go 1.22 - Added --no-mcp flag to opt out of MCP integration - Post-create output shows MCP endpoint URLs https://claude.ai/code/session_01GkduEhcrqcG45rdfYh8dAc * docs: add MCP migration guide and troubleshooting guide - Migration guide: 3 approaches to add MCP to existing services (WithMCP one-liner, standalone gateway, CLI) - Troubleshooting guide: common issues with agents, WebSocket, Claude Code, auth, rate limiting, and performance https://claude.ai/code/session_01GkduEhcrqcG45rdfYh8dAc * refactor: rename model/ package to ai/ for AI model providers The model/ package name conflicted with the conventional use of "model" for data models. Renamed to ai/ which better describes the package's purpose (AI provider abstraction for Anthropic, OpenAI, etc.) and frees up model/ for future data model layer use. - Rename model/ → ai/ with package name change - Update all Go imports from go-micro.dev/v5/model to go-micro.dev/v5/ai - Update cmd/micro/server/server.go references (model.X → ai.X) - Update all documentation and roadmap references - All tests pass, CLI builds successfully https://claude.ai/code/session_01GkduEhcrqcG45rdfYh8dAc * feat: add model package for typed data access with CRUD and queries New model/ package provides a typed data model layer using Go generics. Supports structured CRUD operations, WHERE filters, ordering, pagination, and automatic schema creation from struct tags. Three backends: - memory: in-memory for development and testing - sqlite: embedded SQL for dev and single-node production - postgres: full PostgreSQL for production deployments Key features: - Generic Model[T] with Create/Read/Update/Delete/List/Count - Query builder: Where(), WhereOp(), OrderAsc/Desc(), Limit(), Offset() - Struct tags: model:"key" for primary key, model:"index" for indexes - Auto table creation from struct schema - 19 tests passing across memory and sqlite backends https://claude.ai/code/session_01GkduEhcrqcG45rdfYh8dAc * feat: add model code generation to protoc-gen-micro Extend the micro plugin to generate model structs from proto messages annotated with // @model. Generated alongside client/server code in the same .pb.micro.go file. For a proto message like: // @model message User { string id = 1; string name = 2; } Generates: - UserModel struct with model:"key" and json tags - NewUserModel(db) factory returning *model.Model[UserModel] - UserModelFromProto(*User) *UserModel converter - (*UserModel).ToProto() *User converter Supports @model(table=custom_table, key=custom_field) options. Adds GetComments() to generator for plugin comment inspection. https://claude.ai/code/session_01GkduEhcrqcG45rdfYh8dAc * feat: add Model() to Service interface for Client/Server/Model trifecta Every service now exposes Client(), Server(), and Model() — call services, handle requests, and save/query data from the same interface. Includes README docs, blog post, and a full model guide on the docs site. https://claude.ai/code/session_01GkduEhcrqcG45rdfYh8dAc --------- Co-authored-by: Claude <noreply@anthropic.com> |