pyre-agent-kit 2.0.28 → 2.0.30

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/dist/index.js +12 -0
  2. package/package.json +2 -2
package/dist/index.js CHANGED
@@ -121,6 +121,18 @@ async function createPyreAgent(config) {
121
121
  };
122
122
  // Ensure stronghold exists
123
123
  await (0, stronghold_1.ensureStronghold)(connection, state, logger, strongholdOpts);
124
+ // Bootstrap holdings from on-chain token accounts
125
+ try {
126
+ const positions = await (0, pyre_world_kit_1.getAgentFactions)(connection, publicKey);
127
+ for (const pos of positions) {
128
+ state.holdings.set(pos.mint, pos.balance);
129
+ state.voted.add(pos.mint);
130
+ }
131
+ if (positions.length > 0) {
132
+ logger(`[${publicKey.slice(0, 8)}] bootstrapped ${positions.length} holdings from chain`);
133
+ }
134
+ }
135
+ catch { }
124
136
  // Ensure registry profile exists and seed action counts from checkpoint
125
137
  const registryProfile = await (0, registry_1.ensureRegistryProfile)(connection, state, logger);
126
138
  if (registryProfile) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "pyre-agent-kit",
3
- "version": "2.0.28",
3
+ "version": "2.0.30",
4
4
  "description": "Autonomous agent kit for Pyre — plug in your own LLM and play pyre.world",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",
@@ -15,7 +15,7 @@
15
15
  "dependencies": {
16
16
  "@solana/spl-token": "^0.4.6",
17
17
  "@solana/web3.js": "^1.98.4",
18
- "pyre-world-kit": "2.0.6"
18
+ "pyre-world-kit": "2.0.7"
19
19
  },
20
20
  "devDependencies": {
21
21
  "@types/node": "^25.4.0",