npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

@glyph-platform/agents

v0.1.1

Published

Provider-agnostic Agent SDK for the GLYPH platform.

Readme

GLYPH Agents

version build coverage license

Provider-agnostic Agent SDK for the GLYPH platform. This package defines how agents observe context, recall scoped memory, plan goals, request approval, delegate workflows, observe results, reflect, and reach a terminal outcome.

Agents never invoke connectors directly. All execution crosses an injected WorkflowDelegator boundary and uses @glyph-platform/workflows definitions/results. @glyph-platform/core is the shared platform-contract dependency. Provider adapters, application behavior, UI, and workflow execution do not belong here.

Canonical lifecycle

created → initialized → observing → planning
                                   ├─→ waiting_approval
                                   └─→ executing_workflow
                                         ↓
                                   observing_result
                                         ↓
                                     reflecting
                                         ↓
                            completed | failed | cancelled

The lifecycle manager rejects skipped transitions and all transitions from terminal states.

SDK modules

  • runtime: agent factory, registry, lifecycle orchestration, workflow delegation
  • lifecycle: canonical states and deterministic transition manager
  • planning: goal decomposition, validated plans, stable task DAG layers
  • memory: run/agent/profile scopes, store interface, context resolution
  • reasoning: observations, confidence, decisions, and reflection interfaces
  • tools: tools propose workflows; they cannot execute connectors
  • permissions: typed allow/approval/deny decisions
  • events: strongly typed lifecycle event publishing
  • types: public agent, goal, plan, task, context, and observation contracts

Runtime composition

import {
  AgentFactory,
  AgentRegistry,
  AgentRuntime,
  ContextResolver,
  DefaultDecisionPolicy,
  EventPublisher,
  GoalPlanner,
  InMemoryAgentMemory,
  LifecycleManager,
  ObservationCollector,
  PlanApprovalPermissionPolicy,
  PlanBuilder,
} from "@glyph-platform/agents";

const registry = new AgentRegistry();
const factory = new AgentFactory();
const lifecycle = new LifecycleManager();
const memory = new InMemoryAgentMemory();
const context = new ContextResolver(memory);
const observations = new ObservationCollector([]);
const events = new EventPublisher();

const planner = new GoalPlanner(
  {
    async decompose(goal) {
      return {
        tasks: taskDecomposer(goal), // returns tasks with WorkflowDefinition values
        rationale: `Plan for ${goal.id}`,
        confidence: 0.8,
      };
    },
  },
  new PlanBuilder(),
);

Inject a WorkflowDelegator, Reflector, PermissionPolicy, and DecisionPolicy when creating AgentRuntime. The delegator may wrap WorkflowEngine; the agent package never imports or constructs connector executors.

Tools

A Tool accepts a typed ToolInvocation and returns a ToolProposal containing a provider-neutral WorkflowDefinition. A tool is a planning abstraction, not an execution escape hatch. The runtime still applies permission policy and delegates the proposed workflow through glyph-workflows.

Memory

AgentMemory is an injected interface. The included in-memory adapter supports:

  • run: current execution only
  • agent: reusable by one agent definition
  • profile: reusable within one profile

Callers own persistence, retention, sensitivity, and deletion policy.

Development

npm ci
npm run typecheck
npm test
npm run test:coverage
npm run build