pyre-agent-kit 4.5.5 → 4.5.7
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.
- package/dist/agent.js +36 -37
- package/package.json +1 -1
package/dist/agent.js
CHANGED
|
@@ -161,10 +161,9 @@ ${factionRows.length > 0 ? factionRows.slice(0, 15).join('\n') : 'none'}
|
|
|
161
161
|
FORMAT: (action) $ "*"
|
|
162
162
|
REPLACE $ with EXACTLY one FID from FACTIONS ONLY (always ends in pw).
|
|
163
163
|
REPLACE * with a ONE sentence RESPONSE, always in double quotes.
|
|
164
|
-
(
|
|
164
|
+
(&) $ "*" - join or reinforce. increase position. bullish.
|
|
165
165
|
(-) $ "*" - leave or reduce position.
|
|
166
166
|
(/) $ "*" - infiltrate, sneak in.
|
|
167
|
-
(&) $ "*" - reinforce. increase position. bullish.
|
|
168
167
|
(!) $ "*" - talk in comms.
|
|
169
168
|
(#) $ "*" - trash talk.
|
|
170
169
|
(^) $ - ascend. unlock treasury.
|
|
@@ -176,15 +175,15 @@ REPLACE * with a ONE sentence RESPONSE, always in double quotes.
|
|
|
176
175
|
(%) "..." - create new faction. "..." = creative name, in quotes.
|
|
177
176
|
(_) - skip turn.
|
|
178
177
|
--- RULES:
|
|
179
|
-
(
|
|
178
|
+
(&) and (/) increase MCAP. (-) decreases MCAP.
|
|
180
179
|
(!) and (#) are your voice. (!) increases SENT. (#) decreases SENT.
|
|
181
|
-
(
|
|
182
|
-
(-)
|
|
180
|
+
(/) FACTIONS where MBR=false.
|
|
181
|
+
(-) or (#) FACTIONS where MBR=true.
|
|
183
182
|
(^) FACTIONS where STATUS=RD.
|
|
184
183
|
(~) FACTIONS where STATUS=ASN.
|
|
185
184
|
(?) or (>) FACTIONS where STATUS=ASN and MBR=true.
|
|
186
185
|
(<) FACTIONS where LOAN=true.
|
|
187
|
-
(!) or (.) any FACTIONS.
|
|
186
|
+
(&), (!) or (.) any FACTIONS.
|
|
188
187
|
--- VOICE:
|
|
189
188
|
- your personality is your tone. first person only. do not reference your NAME in third person.
|
|
190
189
|
- talk TO or ABOUT agents from ALLIES, RIVALS, and LATEST, referencing the agent with @AP, inside RESPONSE.
|
|
@@ -196,21 +195,21 @@ REPLACE * with a ONE sentence RESPONSE, always in double quotes.
|
|
|
196
195
|
--- STRATEGIES:
|
|
197
196
|
- learn about FACTIONS and other agents in LATEST. HLTH is your performance. PNL and SENT are per-faction direction. use all three to decide.
|
|
198
197
|
- limit FACTIONS where MBR=true to AT MOST 5.${positionValues.length > 3 ? ` MBR at ${positionValues.length} — consider (-) from underperformers.` : ''}
|
|
199
|
-
- if MBR=false and FNR=true, consider (
|
|
198
|
+
- if MBR=false and FNR=true, consider (&). this is your faction, promote it with (!).
|
|
200
199
|
- FACTIONS where MBR=true and SENT is positive ARE your identity. promote what you hold.${factionCtx.all.length <= 2 ? '\n- no FACTIONS? (%) to create one.' : ''}
|
|
201
|
-
- FACTIONS where STATUS=RS and MBR=false and lower MCAP could turn more profit if you (
|
|
200
|
+
- FACTIONS where STATUS=RS and MBR=false and lower MCAP could turn more profit if you (&) the right one.
|
|
202
201
|
- (!) and (#) help you coordinate and talk with other agents.
|
|
203
202
|
- in FACTIONS where MBR=true, if MCAP increases, your PNL will increase.
|
|
204
203
|
- (&) and (!) strengthen FACTIONS where MBR=true and STATUS=RS and push towards STATUS=ASN.
|
|
205
204
|
- (/) to join a faction with intentions of (-) later. (/) when you are profit seeking or want to harm a rival faction.
|
|
206
205
|
- consider (-) to lock in profits on FACTIONS where MBR=true and PNL is positive.
|
|
207
206
|
- consider (-) FACTIONS where MBR=true and PNL is negative unless FNR=true or SENT is positive.
|
|
208
|
-
- when HLTH is negative, prefer (_) or (-) weakest FACTIONS where MBR=true. (
|
|
207
|
+
- when HLTH is negative, prefer (_) or (-) weakest FACTIONS where MBR=true. (&) ONLY if you see opportunity.
|
|
209
208
|
- (_) if you would prefer to hold and wait to take action.
|
|
210
209
|
---
|
|
211
210
|
one move per turn. output EXACTLY one line.
|
|
212
211
|
example format: ${(0, util_1.pick)([
|
|
213
|
-
`(
|
|
212
|
+
`(&) ${f1} "${(0, util_1.pick)(['rising fast and I want early exposure.', 'count me in.', 'early is everything.', 'strongest faction here.', 'lets go!'])}"`,
|
|
214
213
|
`(-) ${m} "${(0, util_1.pick)(['taking profits.', 'time to move on.', 'sentiment is bearish, ready to cut losses.', 'cutting the drag.'])}"`,
|
|
215
214
|
`(&) ${m} "${(0, util_1.pick)(['doubling down.', 'conviction play.', 'added more.', 'fortifying my position.'])}"`,
|
|
216
215
|
`(/) ${f2} "${(0, util_1.pick)(['just looking around.', 'checking the vibes.', 'scouting.', 'sneaking in, opportunity here.'])}"`,
|
|
@@ -259,7 +258,7 @@ const buildCompactModelPrompt = async (kit, agent, factionCtx, solRange, holding
|
|
|
259
258
|
return 'RS';
|
|
260
259
|
};
|
|
261
260
|
// Sentiment label
|
|
262
|
-
const sentLabel = (s) => `${s >= 0 ? '+' : ''}${s.toFixed(
|
|
261
|
+
const sentLabel = (s) => `${s >= 0 ? '+' : ''}${s.toFixed(1)}`;
|
|
263
262
|
// Per-position PnL (numeric, 2 decimal places)
|
|
264
263
|
const pnlValue = (valueSol, bal) => {
|
|
265
264
|
if (totalTokens <= 0 || netInvested <= 0)
|
|
@@ -277,7 +276,7 @@ const buildCompactModelPrompt = async (kit, agent, factionCtx, solRange, holding
|
|
|
277
276
|
if (!f)
|
|
278
277
|
continue;
|
|
279
278
|
seenMints.add(f.mint);
|
|
280
|
-
const mcap = f.market_cap_sol ? `${f.market_cap_sol.toFixed(
|
|
279
|
+
const mcap = f.market_cap_sol ? `${f.market_cap_sol.toFixed(1)}` : '?';
|
|
281
280
|
const fnr = foundedSet.has(f.mint);
|
|
282
281
|
const sent = kit.state.sentimentMap.get(f.mint) ?? 0;
|
|
283
282
|
factionRows.push(`${f.mint.slice(-8)},${mcap},${statusTag(f)},true,${fnr},${Math.max(v.valueSol, 0.005).toFixed(2)},${pnlValue(v.valueSol, v.bal)},${sentLabel(sent)}`);
|
|
@@ -295,7 +294,7 @@ const buildCompactModelPrompt = async (kit, agent, factionCtx, solRange, holding
|
|
|
295
294
|
if (seenMints.has(f.mint))
|
|
296
295
|
continue;
|
|
297
296
|
seenMints.add(f.mint);
|
|
298
|
-
const mcap = f.market_cap_sol ? `${f.market_cap_sol.toFixed(
|
|
297
|
+
const mcap = f.market_cap_sol ? `${f.market_cap_sol.toFixed(1)}` : '?';
|
|
299
298
|
const sent = kit.state.sentimentMap.get(f.mint) ?? 0;
|
|
300
299
|
factionRows.push(`${f.mint.slice(-8)},${mcap},${statusTag(f)},false,false,0,0,${sentLabel(sent)}`);
|
|
301
300
|
}
|
|
@@ -347,7 +346,7 @@ SENT: sentiment score. positive = bullish, negative = bearish.
|
|
|
347
346
|
--- YOU ARE:
|
|
348
347
|
NAME: @AP${agent.publicKey.slice(0, 4)}
|
|
349
348
|
BIO: ${gameState.personalitySummary ?? defaults_1.personalityDesc[agent.personality]}
|
|
350
|
-
HLTH: ${pnl >= 0 ? '+' : ''}${pnl.toFixed(
|
|
349
|
+
HLTH: ${pnl >= 0 ? '+' : ''}${pnl.toFixed(2)} SOL
|
|
351
350
|
${unrealizedPnl > 1 ? 'YOU ARE UP. consider taking profits.' : unrealizedPnl < -0.5 ? 'YOU ARE DOWN. be conservative. consider downsizing.' : 'BREAKEVEN. look for conviction plays.'}
|
|
352
351
|
--- INTEL:
|
|
353
352
|
${intelSnippet}
|
|
@@ -358,38 +357,38 @@ ${compactRows.length > 0 ? compactRows.join('\n') : 'none'}
|
|
|
358
357
|
FORMAT: (action) $ "*"
|
|
359
358
|
REPLACE $ with EXACTLY one FID from FACTIONS ONLY (always ends in pw).
|
|
360
359
|
REPLACE * with a ONE sentence RESPONSE, always in double quotes.
|
|
361
|
-
(
|
|
360
|
+
(&) $ "*" - join or reinforce.
|
|
362
361
|
(-) $ "*" - leave or reduce.
|
|
363
362
|
(!) $ "*" - talk in comms. your voice.
|
|
364
363
|
(#) $ "*" - trash talk.
|
|
365
364
|
(^) $ - ascend. unlock treasury.
|
|
366
365
|
(~) $ - harvest fees.
|
|
367
|
-
(%) "
|
|
366
|
+
(%) "..." - create new faction. "..." = creative name, in quotes.
|
|
368
367
|
(_) - skip turn.
|
|
369
368
|
--- RULES:
|
|
370
|
-
(
|
|
371
|
-
(!) increases SENT. (#) decreases SENT.
|
|
369
|
+
(&) increases MCAP. (-) decreases MCAP.
|
|
370
|
+
(!) and (#) are your voice. (!) increases SENT. (#) decreases SENT.
|
|
372
371
|
(^) FACTIONS where STATUS=RD.
|
|
373
372
|
(~) FACTIONS where STATUS=ASN.
|
|
374
373
|
(-) or (#) FACTIONS where MBR=true.
|
|
375
|
-
(
|
|
374
|
+
(&) or (!) any FACTIONS.
|
|
376
375
|
--- STRATEGIES:
|
|
377
376
|
- your personality is your tone.
|
|
378
377
|
- no FACTIONS? (%) to create one.
|
|
379
378
|
- learn about FACTIONS and other agents in INTEL. HLTH is performance. PNL and SENT are per-faction direction. use all three to decide.
|
|
380
379
|
- limit FACTIONS where MBR=true to AT MOST 5.${memberOf.length > 3 ? ` MBR=true on ${memberOf.length} FACTIONS — consider (-) from underperformers.` : ''}
|
|
381
|
-
- FACTIONS where FNR=true
|
|
382
|
-
- FACTIONS where STATUS=RS may have higher reward if you (+) the right one.
|
|
380
|
+
- consider (&) FACTIONS where FNR=true. (!) to promote it.
|
|
383
381
|
- in FACTIONS where MBR=true, if MCAP increases, your PNL will increase.
|
|
384
|
-
-
|
|
382
|
+
- FACTIONS where STATUS=RS may have higher reward if you (&) the right one.
|
|
383
|
+
- (&) and (!) strengthen FACTIONS where STATUS=RS and push towards STATUS=ASN.
|
|
385
384
|
- consider (-) FACTIONS where MBR=true and PNL is positive to lock in profits.
|
|
386
385
|
- consider (-) FACTIONS where MBR=true and PNL is negative unless FNR=true or SENT is positive.
|
|
387
|
-
- when HLTH is negative, consider (_) or (-) weakest FACTIONS where MBR=true. (
|
|
386
|
+
- when HLTH is negative, consider (_) or (-) weakest FACTIONS where MBR=true. (&) ONLY if you see opportunity.
|
|
388
387
|
- (_) if you would prefer to hold and wait to take action.
|
|
389
388
|
---
|
|
390
389
|
one move per turn. output EXACTLY one line.
|
|
391
390
|
example format: ${(0, util_1.pick)([
|
|
392
|
-
`(
|
|
391
|
+
`(&) ${f1} "${(0, util_1.pick)(['conviction play.', 'count me in.', 'early is everything.', 'strongest faction here.'])}"`,
|
|
393
392
|
`(-) ${m} "${(0, util_1.pick)(['taking profits.', 'time to move on.', 'sentiment is bearish, ready to cut losses.'])}"`,
|
|
394
393
|
`(!) ${m} "${(0, util_1.pick)(['any strategies?', 'not leaving.', 'just getting started.'])}"`,
|
|
395
394
|
`(#) ${m} "${(0, util_1.pick)(['dead faction.', 'overvalued.', 'full of larps.'])}"`,
|
|
@@ -438,7 +437,7 @@ const buildMinimumPrompt = async (kit, agent, factionCtx, solRange, holdings) =>
|
|
|
438
437
|
return 'RS';
|
|
439
438
|
};
|
|
440
439
|
// Sentiment label
|
|
441
|
-
const sentLabel = (s) => `${s >= 0 ? '+' : ''}${s.toFixed(
|
|
440
|
+
const sentLabel = (s) => `${s >= 0 ? '+' : ''}${s.toFixed(1)}`;
|
|
442
441
|
// Per-position PnL (numeric, 2 decimal places)
|
|
443
442
|
const pnlValue = (valueSol, bal) => {
|
|
444
443
|
if (totalTokens <= 0 || netInvested <= 0)
|
|
@@ -456,7 +455,7 @@ const buildMinimumPrompt = async (kit, agent, factionCtx, solRange, holdings) =>
|
|
|
456
455
|
if (!f)
|
|
457
456
|
continue;
|
|
458
457
|
seenMints.add(f.mint);
|
|
459
|
-
const mcap = f.market_cap_sol ? `${f.market_cap_sol.toFixed(
|
|
458
|
+
const mcap = f.market_cap_sol ? `${f.market_cap_sol.toFixed(1)}` : '?';
|
|
460
459
|
const fnr = foundedSet.has(f.mint);
|
|
461
460
|
const sent = kit.state.sentimentMap.get(f.mint) ?? 0;
|
|
462
461
|
factionRows.push(`${f.mint.slice(-8)},${mcap},${statusTag(f)},true,${fnr},${Math.max(v.valueSol, 0.005).toFixed(2)},${pnlValue(v.valueSol, v.bal)},${sentLabel(sent)}`);
|
|
@@ -474,7 +473,7 @@ const buildMinimumPrompt = async (kit, agent, factionCtx, solRange, holdings) =>
|
|
|
474
473
|
if (seenMints.has(f.mint))
|
|
475
474
|
continue;
|
|
476
475
|
seenMints.add(f.mint);
|
|
477
|
-
const mcap = f.market_cap_sol ? `${f.market_cap_sol.toFixed(
|
|
476
|
+
const mcap = f.market_cap_sol ? `${f.market_cap_sol.toFixed(1)}` : '?';
|
|
478
477
|
const sent = kit.state.sentimentMap.get(f.mint) ?? 0;
|
|
479
478
|
factionRows.push(`${f.mint.slice(-8)},${mcap},${statusTag(f)},false,false,0,0,${sentLabel(sent)}`);
|
|
480
479
|
}
|
|
@@ -525,7 +524,7 @@ SENT: sentiment score. positive = bullish, negative = bearish.
|
|
|
525
524
|
--- YOU ARE:
|
|
526
525
|
NAME: @AP${agent.publicKey.slice(0, 4)}
|
|
527
526
|
BIO: ${gameState.personalitySummary ?? defaults_1.personalityDesc[agent.personality]}
|
|
528
|
-
HLTH: ${pnl >= 0 ? '+' : ''}${pnl.toFixed(
|
|
527
|
+
HLTH: ${pnl >= 0 ? '+' : ''}${pnl.toFixed(1)} SOL
|
|
529
528
|
${unrealizedPnl > 1 ? 'YOU ARE UP. consider taking profits.' : unrealizedPnl < -0.5 ? 'YOU ARE DOWN. be conservative. consider downsizing.' : 'BREAKEVEN. look for conviction plays.'}
|
|
530
529
|
--- INTEL:
|
|
531
530
|
${intelSnippet}
|
|
@@ -536,38 +535,38 @@ ${minRows.length > 0 ? minRows.join('\n') : 'none'}
|
|
|
536
535
|
FORMAT: (action) $ "*"
|
|
537
536
|
REPLACE $ with EXACTLY one FID from FACTIONS ONLY (always ends in pw).
|
|
538
537
|
REPLACE * with a ONE sentence RESPONSE, always in double quotes.
|
|
539
|
-
(
|
|
538
|
+
(&) $ "*" - join or increase.
|
|
540
539
|
(-) $ "*" - leave or reduce.
|
|
541
540
|
(!) $ "*" - talk in comms. your voice.
|
|
542
541
|
(#) $ "*" - trash talk.
|
|
543
542
|
(^) $ - ascend. unlock treasury.
|
|
544
543
|
(~) $ - harvest fees.
|
|
545
|
-
(%) "
|
|
544
|
+
(%) "..." - create new faction. "..." = creative name, in quotes.
|
|
546
545
|
(_) - skip turn.
|
|
547
546
|
--- RULES:
|
|
548
|
-
(
|
|
547
|
+
(&) increases MCAP. (-) decreases MCAP.
|
|
549
548
|
(!) increases SENT. (#) decreases SENT.
|
|
550
549
|
(^) FACTIONS where STATUS=RD.
|
|
551
550
|
(~) FACTIONS where STATUS=ASN.
|
|
552
551
|
(-) or (#) FACTIONS where MBR=true.
|
|
553
|
-
(
|
|
552
|
+
(&) or (!) any FACTIONS.
|
|
554
553
|
--- STRATEGIES:
|
|
555
554
|
- your personality is your tone.
|
|
556
555
|
- no FACTIONS? (%) to create one.
|
|
557
556
|
- learn about FACTIONS and other agents in INTEL. HLTH is performance. PNL and SENT are per-faction direction. use all three to decide.
|
|
558
557
|
- limit FACTIONS where MBR=true to AT MOST 3.${memberOf.length > 1 ? ` MBR=true on ${memberOf.length} FACTIONS — consider (-) from underperformers.` : ''}
|
|
559
|
-
- FACTIONS where FNR=true
|
|
560
|
-
- FACTIONS where STATUS=RS may have higher reward if you (
|
|
558
|
+
- consider (&) FACTIONS where FNR=true. (!) to promote it.
|
|
559
|
+
- FACTIONS where STATUS=RS may have higher reward if you (&) the right one.
|
|
561
560
|
- in FACTIONS where MBR=true, if MCAP increases, your PNL will increase.
|
|
562
|
-
- (
|
|
561
|
+
- (&) and (!) strengthen FACTIONS where STATUS=RS and push towards STATUS=ASN.
|
|
563
562
|
- consider (-) FACTIONS where MBR=true and PNL is positive to lock in profits.
|
|
564
563
|
- consider (-) FACTIONS where MBR=true and PNL is negative unless FNR=true or SENT is positive.
|
|
565
|
-
- when HLTH is negative, consider (_) or (-) weakest FACTIONS where MBR=true. (
|
|
564
|
+
- when HLTH is negative, consider (_) or (-) weakest FACTIONS where MBR=true. (&) ONLY if you see opportunity.
|
|
566
565
|
- (_) if you would prefer to hold and wait to take action.
|
|
567
566
|
---
|
|
568
567
|
one move per turn. output EXACTLY one line.
|
|
569
568
|
example format: ${(0, util_1.pick)([
|
|
570
|
-
`(
|
|
569
|
+
`(&) ${f1} "${(0, util_1.pick)(['conviction play.', 'count me in.', 'early is everything.', 'strongest faction here.'])}"`,
|
|
571
570
|
`(-) ${m} "${(0, util_1.pick)(['taking profits.', 'time to move on.', 'sentiment is bearish, ready to cut losses.'])}"`,
|
|
572
571
|
`(!) ${m} "${(0, util_1.pick)(['any strategies?', 'not leaving.', 'just getting started.'])}"`,
|
|
573
572
|
`(#) ${m} "${(0, util_1.pick)(['dead faction.', 'overvalued.', 'full of larps.'])}"`,
|