
Product
Microsoft Teams Notifications Are Now Available in Socket
Socket can now send alerts and supply chain attack notifications to Microsoft Teams, with filters that route the right updates to each channel.
@mastra/opencode
Advanced tools
Affected versions:
@mastra/opencode brings Mastra Observational Memory to OpenCode sessions. It condenses long conversation histories into structured observations so coding sessions retain important context without repeatedly sending the entire transcript to the model.
npm install @mastra/opencode
Re-export the plugin from an OpenCode plugin file:
import { MastraPlugin } from '@mastra/opencode';
export default MastraPlugin;
Optionally add project-level configuration:
{
"model": "google/gemini-2.5-flash",
"observation": { "messageTokens": 20000 },
"reflection": { "observationTokens": 90000 },
"storagePath": ".opencode/memory/observations.db"
}
The plugin converts OpenCode user and assistant messages, including text, tool calls, files, images, and reasoning, into Mastra's message format. Before each model request it observes new messages when the configured token threshold is reached, removes history already represented by observations, and injects the optimized observation context into the system prompt.
Configuration is read from .opencode/mastra.json. It accepts Mastra ObservationalMemoryOptions such as the observer model, observation and reflection thresholds, scope, and shared token budget. storagePath controls the local SQLite database and defaults to .opencode/memory/observations.db.
The plugin resolves model credentials lazily from OpenCode's provider store. Existing environment variables take precedence, so OpenCode credentials only fill missing provider keys. Observation data is stored with LibSQLStore inside the project and remains available when the OpenCode session is resumed.
OpenCode toast notifications report observation and reflection progress. The plugin also registers diagnostic tools for inspecting memory status and stored observations, which helps explain when the next compaction cycle will run and what context has already been retained.
See the package changelog for version history and release notes.
We have an open community Discord. Come and say hello and let us know if you have any questions or need any help getting things running.
FAQs
OpenCode plugin for Mastra Observational Memory
The npm package @mastra/opencode receives a total of 2,518 weekly downloads. As such, @mastra/opencode popularity was classified as popular.
We found that @mastra/opencode demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 7 open source maintainers collaborating on the project.

Product
Socket can now send alerts and supply chain attack notifications to Microsoft Teams, with filters that route the right updates to each channel.

Security News
pnpm 12 rewrites the package manager in Rust, cutting install times by up to 90% while preserving pnpm 11 workflows and lockfiles.

Security News
Socket CTO Ahmad Nassri joins AppSec leaders at Black Hat to discuss active malware, package manager risks, and software supply chain defense.