npcsh 1.1.4__py3-none-any.whl → 1.1.6__py3-none-any.whl

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 (102) hide show
  1. npcsh/_state.py +470 -367
  2. npcsh/npc_team/corca_example.png +0 -0
  3. npcsh/npc_team/jinxs/{python_executor.jinx → code/python.jinx} +1 -1
  4. npcsh/npc_team/jinxs/{bash_executer.jinx → code/sh.jinx} +1 -2
  5. npcsh/npc_team/jinxs/code/sql.jinx +16 -0
  6. npcsh/npc_team/jinxs/modes/alicanto.jinx +88 -0
  7. npcsh/npc_team/jinxs/modes/corca.jinx +28 -0
  8. npcsh/npc_team/jinxs/modes/guac.jinx +46 -0
  9. npcsh/npc_team/jinxs/modes/plonk.jinx +57 -0
  10. npcsh/npc_team/jinxs/modes/pti.jinx +28 -0
  11. npcsh/npc_team/jinxs/modes/spool.jinx +40 -0
  12. npcsh/npc_team/jinxs/modes/wander.jinx +81 -0
  13. npcsh/npc_team/jinxs/modes/yap.jinx +25 -0
  14. npcsh/npc_team/jinxs/utils/breathe.jinx +20 -0
  15. npcsh/npc_team/jinxs/utils/core/build.jinx +65 -0
  16. npcsh/npc_team/jinxs/utils/core/compile.jinx +50 -0
  17. npcsh/npc_team/jinxs/utils/core/help.jinx +52 -0
  18. npcsh/npc_team/jinxs/utils/core/init.jinx +41 -0
  19. npcsh/npc_team/jinxs/utils/core/jinxs.jinx +32 -0
  20. npcsh/npc_team/jinxs/utils/core/set.jinx +40 -0
  21. npcsh/npc_team/jinxs/{edit_file.jinx → utils/edit_file.jinx} +1 -1
  22. npcsh/npc_team/jinxs/utils/flush.jinx +39 -0
  23. npcsh/npc_team/jinxs/utils/npc-studio.jinx +77 -0
  24. npcsh/npc_team/jinxs/utils/ots.jinx +61 -0
  25. npcsh/npc_team/jinxs/utils/plan.jinx +33 -0
  26. npcsh/npc_team/jinxs/utils/roll.jinx +66 -0
  27. npcsh/npc_team/jinxs/utils/sample.jinx +56 -0
  28. npcsh/npc_team/jinxs/utils/search.jinx +130 -0
  29. npcsh/npc_team/jinxs/utils/serve.jinx +29 -0
  30. npcsh/npc_team/jinxs/utils/sleep.jinx +116 -0
  31. npcsh/npc_team/jinxs/utils/trigger.jinx +36 -0
  32. npcsh/npc_team/jinxs/utils/vixynt.jinx +117 -0
  33. npcsh/npcsh.py +13 -11
  34. npcsh/routes.py +97 -1419
  35. npcsh-1.1.6.data/data/npcsh/npc_team/alicanto.jinx +88 -0
  36. npcsh-1.1.6.data/data/npcsh/npc_team/breathe.jinx +20 -0
  37. npcsh-1.1.6.data/data/npcsh/npc_team/build.jinx +65 -0
  38. npcsh-1.1.6.data/data/npcsh/npc_team/compile.jinx +50 -0
  39. npcsh-1.1.6.data/data/npcsh/npc_team/corca.jinx +28 -0
  40. npcsh-1.1.6.data/data/npcsh/npc_team/corca_example.png +0 -0
  41. {npcsh-1.1.4.data → npcsh-1.1.6.data}/data/npcsh/npc_team/edit_file.jinx +1 -1
  42. npcsh-1.1.6.data/data/npcsh/npc_team/flush.jinx +39 -0
  43. npcsh-1.1.6.data/data/npcsh/npc_team/guac.jinx +46 -0
  44. npcsh-1.1.6.data/data/npcsh/npc_team/help.jinx +52 -0
  45. npcsh-1.1.6.data/data/npcsh/npc_team/init.jinx +41 -0
  46. npcsh-1.1.6.data/data/npcsh/npc_team/jinxs.jinx +32 -0
  47. npcsh-1.1.6.data/data/npcsh/npc_team/npc-studio.jinx +77 -0
  48. npcsh-1.1.6.data/data/npcsh/npc_team/ots.jinx +61 -0
  49. npcsh-1.1.6.data/data/npcsh/npc_team/plan.jinx +33 -0
  50. npcsh-1.1.6.data/data/npcsh/npc_team/plonk.jinx +57 -0
  51. npcsh-1.1.6.data/data/npcsh/npc_team/pti.jinx +28 -0
  52. npcsh-1.1.4.data/data/npcsh/npc_team/python_executor.jinx → npcsh-1.1.6.data/data/npcsh/npc_team/python.jinx +1 -1
  53. npcsh-1.1.6.data/data/npcsh/npc_team/roll.jinx +66 -0
  54. npcsh-1.1.6.data/data/npcsh/npc_team/sample.jinx +56 -0
  55. npcsh-1.1.6.data/data/npcsh/npc_team/search.jinx +130 -0
  56. npcsh-1.1.6.data/data/npcsh/npc_team/serve.jinx +29 -0
  57. npcsh-1.1.6.data/data/npcsh/npc_team/set.jinx +40 -0
  58. npcsh-1.1.4.data/data/npcsh/npc_team/bash_executer.jinx → npcsh-1.1.6.data/data/npcsh/npc_team/sh.jinx +1 -2
  59. npcsh-1.1.6.data/data/npcsh/npc_team/sleep.jinx +116 -0
  60. npcsh-1.1.6.data/data/npcsh/npc_team/spool.jinx +40 -0
  61. npcsh-1.1.6.data/data/npcsh/npc_team/sql.jinx +16 -0
  62. npcsh-1.1.6.data/data/npcsh/npc_team/trigger.jinx +36 -0
  63. npcsh-1.1.6.data/data/npcsh/npc_team/vixynt.jinx +117 -0
  64. npcsh-1.1.6.data/data/npcsh/npc_team/wander.jinx +81 -0
  65. npcsh-1.1.6.data/data/npcsh/npc_team/yap.jinx +25 -0
  66. {npcsh-1.1.4.dist-info → npcsh-1.1.6.dist-info}/METADATA +1 -10
  67. npcsh-1.1.6.dist-info/RECORD +124 -0
  68. npcsh/npc_team/jinxs/image_generation.jinx +0 -29
  69. npcsh/npc_team/jinxs/internet_search.jinx +0 -31
  70. npcsh/npc_team/jinxs/kg_search.jinx +0 -43
  71. npcsh/npc_team/jinxs/memory_search.jinx +0 -36
  72. npcsh/npc_team/jinxs/screen_cap.jinx +0 -25
  73. npcsh-1.1.4.data/data/npcsh/npc_team/image_generation.jinx +0 -29
  74. npcsh-1.1.4.data/data/npcsh/npc_team/internet_search.jinx +0 -31
  75. npcsh-1.1.4.data/data/npcsh/npc_team/kg_search.jinx +0 -43
  76. npcsh-1.1.4.data/data/npcsh/npc_team/memory_search.jinx +0 -36
  77. npcsh-1.1.4.data/data/npcsh/npc_team/screen_cap.jinx +0 -25
  78. npcsh-1.1.4.dist-info/RECORD +0 -78
  79. {npcsh-1.1.4.data → npcsh-1.1.6.data}/data/npcsh/npc_team/alicanto.npc +0 -0
  80. {npcsh-1.1.4.data → npcsh-1.1.6.data}/data/npcsh/npc_team/alicanto.png +0 -0
  81. {npcsh-1.1.4.data → npcsh-1.1.6.data}/data/npcsh/npc_team/corca.npc +0 -0
  82. {npcsh-1.1.4.data → npcsh-1.1.6.data}/data/npcsh/npc_team/corca.png +0 -0
  83. {npcsh-1.1.4.data → npcsh-1.1.6.data}/data/npcsh/npc_team/foreman.npc +0 -0
  84. {npcsh-1.1.4.data → npcsh-1.1.6.data}/data/npcsh/npc_team/frederic.npc +0 -0
  85. {npcsh-1.1.4.data → npcsh-1.1.6.data}/data/npcsh/npc_team/frederic4.png +0 -0
  86. {npcsh-1.1.4.data → npcsh-1.1.6.data}/data/npcsh/npc_team/guac.png +0 -0
  87. {npcsh-1.1.4.data → npcsh-1.1.6.data}/data/npcsh/npc_team/kadiefa.npc +0 -0
  88. {npcsh-1.1.4.data → npcsh-1.1.6.data}/data/npcsh/npc_team/kadiefa.png +0 -0
  89. {npcsh-1.1.4.data → npcsh-1.1.6.data}/data/npcsh/npc_team/npcsh.ctx +0 -0
  90. {npcsh-1.1.4.data → npcsh-1.1.6.data}/data/npcsh/npc_team/npcsh_sibiji.png +0 -0
  91. {npcsh-1.1.4.data → npcsh-1.1.6.data}/data/npcsh/npc_team/plonk.npc +0 -0
  92. {npcsh-1.1.4.data → npcsh-1.1.6.data}/data/npcsh/npc_team/plonk.png +0 -0
  93. {npcsh-1.1.4.data → npcsh-1.1.6.data}/data/npcsh/npc_team/plonkjr.npc +0 -0
  94. {npcsh-1.1.4.data → npcsh-1.1.6.data}/data/npcsh/npc_team/plonkjr.png +0 -0
  95. {npcsh-1.1.4.data → npcsh-1.1.6.data}/data/npcsh/npc_team/sibiji.npc +0 -0
  96. {npcsh-1.1.4.data → npcsh-1.1.6.data}/data/npcsh/npc_team/sibiji.png +0 -0
  97. {npcsh-1.1.4.data → npcsh-1.1.6.data}/data/npcsh/npc_team/spool.png +0 -0
  98. {npcsh-1.1.4.data → npcsh-1.1.6.data}/data/npcsh/npc_team/yap.png +0 -0
  99. {npcsh-1.1.4.dist-info → npcsh-1.1.6.dist-info}/WHEEL +0 -0
  100. {npcsh-1.1.4.dist-info → npcsh-1.1.6.dist-info}/entry_points.txt +0 -0
  101. {npcsh-1.1.4.dist-info → npcsh-1.1.6.dist-info}/licenses/LICENSE +0 -0
  102. {npcsh-1.1.4.dist-info → npcsh-1.1.6.dist-info}/top_level.txt +0 -0
@@ -0,0 +1,117 @@
1
+ jinx_name: "vixynt"
2
+ description: "Generates images from text descriptions or edits existing ones."
3
+ inputs:
4
+ - prompt
5
+ - model: ""
6
+ - provider: ""
7
+ - output_name: ""
8
+ - attachments: ""
9
+ - n_images: 1
10
+ - height: 1024
11
+ - width: 1024
12
+ steps:
13
+ - name: "generate_or_edit_image"
14
+ engine: "python"
15
+ code: |
16
+ import os
17
+ import base64
18
+ from io import BytesIO
19
+ from datetime import datetime
20
+ from PIL import Image
21
+ from npcpy.llm_funcs import gen_image
22
+
23
+ # Extract inputs from context
24
+ image_prompt = context.get('prompt', '').strip()
25
+ output_name = context.get('output_name')
26
+ attachments_str = context.get('attachments')
27
+ n_images = int(context.get('n_images', 1))
28
+ height = int(context.get('height', 1024))
29
+ width = int(context.get('width', 1024))
30
+ model = context.get('model')
31
+ provider = context.get('provider')
32
+
33
+ input_images = []
34
+ if attachments_str and attachments_str.strip():
35
+ input_images = [p.strip() for p in attachments_str.split(',')]
36
+
37
+ # Use NPC's model/provider as fallback
38
+ if not model and npc and npc.model:
39
+ model = npc.model
40
+ if not provider and npc and npc.provider:
41
+ provider = npc.provider
42
+
43
+ # Final fallbacks
44
+ if not model:
45
+ model = "runwayml/stable-diffusion-v1-5"
46
+ if not provider:
47
+ provider = "diffusers"
48
+
49
+ output_messages = context.get('messages', [])
50
+
51
+ if not image_prompt:
52
+ context['output'] = "Error: No prompt provided for image generation."
53
+ context['messages'] = output_messages
54
+ exit()
55
+
56
+ try:
57
+ # Generate image(s)
58
+ result = gen_image(
59
+ prompt=image_prompt,
60
+ model=model,
61
+ provider=provider,
62
+ npc=npc,
63
+ height=height,
64
+ width=width,
65
+ n_images=n_images,
66
+ input_images=input_images if input_images else None
67
+ )
68
+
69
+ # Ensure we have a list of images
70
+ if not isinstance(result, list):
71
+ images_list = [result] if result is not None else []
72
+ else:
73
+ images_list = result
74
+
75
+ saved_files = []
76
+
77
+ for i, image in enumerate(images_list):
78
+ if image is None:
79
+ continue
80
+
81
+ # Determine output filename
82
+ if output_name and output_name.strip():
83
+ base_name, ext = os.path.splitext(os.path.expanduser(output_name))
84
+ if not ext:
85
+ ext = ".png"
86
+ current_output_file = f"{base_name}_{i}{ext}" if len(images_list) > 1 else f"{base_name}{ext}"
87
+ else:
88
+ os.makedirs(os.path.expanduser("~/.npcsh/images/"), exist_ok=True)
89
+ current_output_file = (
90
+ os.path.expanduser("~/.npcsh/images/")
91
+ + f"image_{datetime.now().strftime('%Y%m%d_%H%M%S')}_{i}.png"
92
+ )
93
+
94
+ # Save image to file
95
+ image.save(current_output_file)
96
+ saved_files.append(current_output_file)
97
+
98
+ if saved_files:
99
+ if input_images:
100
+ output = f"Image(s) edited and saved to: {', '.join(saved_files)}"
101
+ else:
102
+ output = f"Image(s) generated and saved to: {', '.join(saved_files)}"
103
+
104
+ # DO NOT include base64 data - just reference the file paths
105
+ output += f"\n\nThe image files have been saved and are ready to view."
106
+ else:
107
+ output = "No images were generated."
108
+
109
+ except Exception as e:
110
+ import traceback
111
+ traceback.print_exc()
112
+ output = f"Error {'editing' if input_images else 'generating'} image: {str(e)}"
113
+
114
+ context['output'] = output
115
+ context['messages'] = output_messages
116
+ context['model'] = model
117
+ context['provider'] = provider
@@ -0,0 +1,81 @@
1
+ jinx_name: "wander"
2
+ description: "Enter wander mode (experimental)"
3
+ inputs:
4
+ - problem: "" # The problem to wander about.
5
+ - environment: "" # Optional environment for wander mode.
6
+ - low_temp: 0.5 # Low temperature setting for LLM.
7
+ - high_temp: 1.9 # High temperature setting for LLM.
8
+ - interruption_likelihood: 1.0 # Likelihood of interruption.
9
+ - sample_rate: 0.4 # Sample rate.
10
+ - n_high_temp_streams: 5 # Number of high temperature streams.
11
+ - include_events: False # Whether to include events.
12
+ - num_events: 3 # Number of events to include.
13
+ steps:
14
+ - name: "enter_wander"
15
+ engine: "python"
16
+ code: |
17
+ import traceback
18
+ from npcsh.wander import enter_wander_mode
19
+
20
+ problem = context.get('problem')
21
+ environment = context.get('environment')
22
+ low_temp = float(context.get('low_temp', 0.5)) # Ensure float type
23
+ high_temp = float(context.get('high_temp', 1.9)) # Ensure float type
24
+ interruption_likelihood = float(context.get('interruption_likelihood', 1.0)) # Ensure float type
25
+ sample_rate = float(context.get('sample_rate', 0.4)) # Ensure float type
26
+ n_high_temp_streams = int(context.get('n_high_temp_streams', 5)) # Ensure int type
27
+ include_events = context.get('include_events', False) # Boolean type
28
+ num_events = int(context.get('num_events', 3)) # Ensure int type
29
+
30
+ current_npc = context.get('npc')
31
+ llm_model = context.get('model')
32
+ llm_provider = context.get('provider')
33
+ output_messages = context.get('messages', [])
34
+
35
+ if not problem or not problem.strip():
36
+ context['output'] = "Usage: /wander <problem> [key=value...]"
37
+ context['messages'] = output_messages
38
+ exit()
39
+
40
+ # Fallback for model/provider if not explicitly set in Jinx inputs
41
+ if not llm_model and current_npc and current_npc.model:
42
+ llm_model = current_npc.model
43
+ if not llm_provider and current_npc and current_npc.provider:
44
+ llm_provider = current_npc.provider
45
+
46
+ # Final fallbacks (these would ideally come from npcsh._state config)
47
+ if not llm_model: llm_model = "gemini-1.5-pro" # Example default
48
+ if not llm_provider: llm_provider = "gemini" # Example default
49
+
50
+ try:
51
+ mode_args = {
52
+ 'problem': problem,
53
+ 'npc': current_npc,
54
+ 'model': llm_model,
55
+ 'provider': llm_provider,
56
+ 'environment': environment,
57
+ 'low_temp': low_temp,
58
+ 'high_temp': high_temp,
59
+ 'interruption_likelihood': interruption_likelihood,
60
+ 'sample_rate': sample_rate,
61
+ 'n_high_temp_streams': n_high_temp_streams,
62
+ 'include_events': include_events,
63
+ 'num_events': num_events
64
+ }
65
+
66
+ result = enter_wander_mode(**mode_args)
67
+
68
+ output_result = ""
69
+ if isinstance(result, list) and result:
70
+ output_result = result[-1].get("insight", "Wander mode session complete.")
71
+ else:
72
+ output_result = str(result) if result else "Wander mode session complete."
73
+
74
+ output_messages.append({"role": "assistant", "content": output_result})
75
+ context['output'] = output_result
76
+ context['messages'] = output_messages
77
+
78
+ except Exception as e:
79
+ traceback.print_exc()
80
+ context['output'] = f"Error during wander mode: {e}"
81
+ context['messages'] = output_messages
@@ -0,0 +1,25 @@
1
+ jinx_name: "yap"
2
+ description: "Enter voice chat (yap) mode"
3
+ inputs: [] # Yap mode takes its parameters directly from the environment/kwargs
4
+ steps:
5
+ - name: "enter_yap"
6
+ engine: "python"
7
+ code: |
8
+ import traceback
9
+ from npcsh.yap import enter_yap_mode
10
+
11
+ output_messages = context.get('messages', [])
12
+
13
+ try:
14
+ result = enter_yap_mode(**context) # Pass all context as kwargs
15
+
16
+ if isinstance(result, dict):
17
+ context['output'] = result.get('output', 'Exited Yap Mode.')
18
+ context['messages'] = result.get('messages', output_messages)
19
+ else:
20
+ context['output'] = str(result)
21
+ context['messages'] = output_messages
22
+ except Exception as e:
23
+ traceback.print_exc()
24
+ context['output'] = f"Error entering yap mode: {e}"
25
+ context['messages'] = output_messages
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: npcsh
3
- Version: 1.1.4
3
+ Version: 1.1.6
4
4
  Summary: npcsh is a command-line toolkit for using AI agents in novel ways.
5
5
  Home-page: https://github.com/NPC-Worldwide/npcsh
6
6
  Author: Christopher Agostino
@@ -142,15 +142,6 @@ and you will enter the NPC shell. Additionally, the pip installation includes th
142
142
  npcsh>please read through the markdown files in the docs folder and suggest changes based on the current implementation in the src folder
143
143
  ```
144
144
 
145
- - **Ask a Generic Question**
146
- ```bash
147
- npcsh> has there ever been a better pasta shape than bucatini?
148
- ```
149
- ```
150
- Bucatini is certainly a favorite for many due to its unique hollow center, which holds sauces beautifully. Whether it's "better" is subjective and depends on the dish and personal
151
- preference. Shapes like orecchiette, rigatoni, or trofie excel in different recipes. Bucatini stands out for its versatility and texture, making it a top contender among pasta shapes!
152
- ```
153
-
154
145
 
155
146
  - **Search the Web**
156
147
  ```bash
@@ -0,0 +1,124 @@
1
+ npcsh/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
2
+ npcsh/_state.py,sha256=TFJXGwhsWEUDxa2Aul2zmhMMEo7lBgdL2Io3mfKClss,100485
3
+ npcsh/alicanto.py,sha256=QCuTtMOgjFkjfrwZZdZBhfp-ETbimlOrXJQiZhClzT0,42160
4
+ npcsh/build.py,sha256=UuId0_rQml40A4U1KuvMekRyfB30s8HiLsXFJjqrBmM,7692
5
+ npcsh/corca.py,sha256=bhEzGlmnq_-VXksuQm6yEdDBgd_-x5WKlt27hw7YVcQ,60698
6
+ npcsh/guac.py,sha256=sVdLYVkzkQw6TE7crtLUX0QJZFkzQthWZTe1p7IfAQE,80412
7
+ npcsh/mcp_helpers.py,sha256=9TsCfcquGu_vX4WaKlY3J3P13-uxruQKrXng-jJ5YyY,11176
8
+ npcsh/mcp_server.py,sha256=Lfpabnwi_xu0UudJxQ_YNyyCn2f0_JjzorhWmIeclwY,8777
9
+ npcsh/npc.py,sha256=yqgqZDLwqniIbbDu-vaJf31fWVbOrtgNnFXfjDBk-D8,9853
10
+ npcsh/npcsh.py,sha256=T6iE_tAV_yWYkxFB1Z0qhYrQxrE-eyh1RmaIQA-3xDQ,9383
11
+ npcsh/plonk.py,sha256=IfOuiE5FBvk-EIsrWFjGy0SrNywDpn4a49E7seBtEmY,14246
12
+ npcsh/pti.py,sha256=UciiiH2Kz4ERQFy0-FX6BQEU2VxYQEUril-_Cvj76Y0,7853
13
+ npcsh/routes.py,sha256=nlp_rd8eDyg2vTuXom9JMtmkWSzISu9u6Oc0lJjxKsQ,5024
14
+ npcsh/spool.py,sha256=oCive2dbn1o3UGUJnFMzfON6g4bOnauuzyyQBgul6RI,9839
15
+ npcsh/wander.py,sha256=8WOX8az8BXjizXGraEvu-ZVphi6PECKZzo9alTK4gmA,21730
16
+ npcsh/yap.py,sha256=QU-j9eg8zixXG6nyjoIYXsanJ4FjPnzhS4aJ241HLxw,18467
17
+ npcsh/npc_team/alicanto.npc,sha256=y9yDY3lq8ZwxQxpnrgle8w5IJwZqvxDepZFU4OaZCtg,148
18
+ npcsh/npc_team/alicanto.png,sha256=A7xeMbcoKGjlkELxJEVifCEZLVWbOKZarTN5ZFJG-FM,3519858
19
+ npcsh/npc_team/corca.npc,sha256=NtZW1mQ_AMOHlfMCfl8A3uA00UMuHuO95FzRg6kUixo,631
20
+ npcsh/npc_team/corca.png,sha256=0lF70hKu6tY-37YmIPVF2cuaPzvnQ4-UtQOzuAbKEf4,1666776
21
+ npcsh/npc_team/corca_example.png,sha256=p0lVTuwaps4-F-3k4wgp9d897YPyn6FGZugtXMUQjj8,28777
22
+ npcsh/npc_team/foreman.npc,sha256=WqB8jLfBToGmr8c1vip1KOnTHxfXlGXwDUGnZoDMQr0,327
23
+ npcsh/npc_team/frederic.npc,sha256=EE2dOUItp-VKuW3ZMSHffmIEO4evjPcU2W_C4P3WXbY,362
24
+ npcsh/npc_team/frederic4.png,sha256=ll8uoV0npnPp5HVJWv7h0xDSeuq4pqsk_gYGBHLS0VY,1590744
25
+ npcsh/npc_team/guac.png,sha256=MCE7eJuEJwLJEzc9FS7lL62Mm-38jQRHkxXogPfOTuw,211470
26
+ npcsh/npc_team/kadiefa.npc,sha256=Yl5a4wrfe4F2f6Ndw_ukzlVVX7NE9g_mG-3QqJSkg_o,381
27
+ npcsh/npc_team/kadiefa.png,sha256=3CAwL8crKIwJko6o75Z6OYYEEM9Rk--yGzCJg7zoszg,3062528
28
+ npcsh/npc_team/npcsh.ctx,sha256=-jKYaPm2YbZHAGgWAXhyPIwhiNe1H1ZRFg1Zc7tHSxk,1049
29
+ npcsh/npc_team/npcsh_sibiji.png,sha256=9fUqgYMsSHmaH-kBTBQ7N5UCS5-eLZF94Log0O3mtFg,4544
30
+ npcsh/npc_team/plonk.npc,sha256=u1m2a1D512XGQ2kC3eWDAY8Y2IvpkNU73DI_CPE65UE,90
31
+ npcsh/npc_team/plonk.png,sha256=IU5ey-Dl4HEKlwnf75RSWNSHpF8rVqGmdbsa0deL4rQ,2727773
32
+ npcsh/npc_team/plonkjr.npc,sha256=It-i-BEuG0XddKk0d85onk2aJr9Pe5pLnJzNaCWaQIM,87
33
+ npcsh/npc_team/plonkjr.png,sha256=MqLEGwsyECUeODZIti0HQQrMMVxA6XERpW01R06NbpY,2606710
34
+ npcsh/npc_team/sibiji.npc,sha256=Hb4wXKIObKKgibwnio5hLec9yd_9bKDCA87Nm2zijFA,216
35
+ npcsh/npc_team/sibiji.png,sha256=1dlZb7J3E62FcVo9CVOzLb8nu1bIUV7cr97nsFocHCM,35615
36
+ npcsh/npc_team/spool.png,sha256=LWTLkwDxXBfLuSUCX32_lo5yAmLYGsA67Xpsz-7MmWU,2876725
37
+ npcsh/npc_team/yap.png,sha256=_l7UbWnXJdsy4Mx-x5l9DT0R6ize3HTnkwQQnOFlI18,1548649
38
+ npcsh/npc_team/jinxs/code/python.jinx,sha256=lFJubdPVlGxSuUKCxsxjYG4_dnX2ATn8U9ChYKRmL5Q,389
39
+ npcsh/npc_team/jinxs/code/sh.jinx,sha256=Z_Cuok4FDUxuZGPCuqWS9D3TPI9SdkaZY4U_TCnie2g,666
40
+ npcsh/npc_team/jinxs/code/sql.jinx,sha256=U3scchBO3tqCQRIErC-W87eLtiCv-YGmN7ftqyIvcVc,582
41
+ npcsh/npc_team/jinxs/modes/alicanto.jinx,sha256=MknpYUX0eIvi5vG9gkoTkJvF_LcFbAp_hQ0qkYEBr3c,4014
42
+ npcsh/npc_team/jinxs/modes/corca.jinx,sha256=OFzxSHoBJ2Yoc34mtTpd9B_CtGdqbpgcCN3Qt39YJeA,1028
43
+ npcsh/npc_team/jinxs/modes/guac.jinx,sha256=UIVXw8c-m-lh10bxL2yl2n94TQ_SjZSwLP3sLFGv0k4,1616
44
+ npcsh/npc_team/jinxs/modes/plonk.jinx,sha256=3f5MvkYBFh5Z3iDhs5vFxPT6acgw7OZLqVA-Mxtm_vc,2559
45
+ npcsh/npc_team/jinxs/modes/pti.jinx,sha256=Yw32GQS9LvYkukEfjq6R1GLAL6fWACYBz9JuVecZJEo,1126
46
+ npcsh/npc_team/jinxs/modes/spool.jinx,sha256=A4upAI4LnXxYUjY0Rz1_kAhRCDpz08XWPTgisiH06A4,1664
47
+ npcsh/npc_team/jinxs/modes/wander.jinx,sha256=Svc6zjmoXr4BbDg5SN4DB1Byhh75AmIeAItcJCBIlcc,3513
48
+ npcsh/npc_team/jinxs/modes/yap.jinx,sha256=eaI665zjaLH2FUwHoO3iC1Uzo9bGA-a1UMtBRBTEHC0,898
49
+ npcsh/npc_team/jinxs/utils/breathe.jinx,sha256=WDw13P3Q0M03HdZu-vqhbOhefLjaMZ5oUcct_W4kUsY,739
50
+ npcsh/npc_team/jinxs/utils/edit_file.jinx,sha256=jExsHctvapG2xlze6E7ZR3oSLS9hJTYKKd41dQwgOLw,3488
51
+ npcsh/npc_team/jinxs/utils/flush.jinx,sha256=ngzFu4-dnKkqqL0QM9iX9XBxyWOmQdVcJTFb1GhajVo,1422
52
+ npcsh/npc_team/jinxs/utils/npc-studio.jinx,sha256=0aY-z399BRIXIL3TLMTcYDiHjDm-krZy0CnYfiskQUo,2234
53
+ npcsh/npc_team/jinxs/utils/ots.jinx,sha256=5Dpsyf0h2M80mkdZnouMp1PSK9S0TCPrINRLoP_1tOc,2303
54
+ npcsh/npc_team/jinxs/utils/plan.jinx,sha256=hCIG9nGI56C1SeGuGAUcR3XnJ25kHaDnUn1VCv8vszY,1234
55
+ npcsh/npc_team/jinxs/utils/roll.jinx,sha256=FHoqXXqFgucaW7UJW_14DcRcRlVPBgFeaPJPoATx5BY,2882
56
+ npcsh/npc_team/jinxs/utils/sample.jinx,sha256=7cWwfAZFgWxaTkIL1gpFFryQ3mjvVjoWYAov-zOFn_E,2237
57
+ npcsh/npc_team/jinxs/utils/search.jinx,sha256=7R37sElFo-XooRNKYqHaouQ-lOxmAxew_8uSXQfNP_Q,5421
58
+ npcsh/npc_team/jinxs/utils/serve.jinx,sha256=qly_3MThU3TRyJI2grHlhYOqEY1VT-XxubPIuWdZrpU,1056
59
+ npcsh/npc_team/jinxs/utils/sleep.jinx,sha256=c-7Dn4aLuX7WyBVcvuk3sqcbIutqKIz1N9sBfPNzhck,5301
60
+ npcsh/npc_team/jinxs/utils/trigger.jinx,sha256=rS913e2qJzNBC0wmmecgzN3f4v8o1os8AZQOPjnW8ho,1456
61
+ npcsh/npc_team/jinxs/utils/vixynt.jinx,sha256=ECNE02omzgvJ2B8ZO8K6OylMa3lLGBNEEeFZ-oXiKC0,4070
62
+ npcsh/npc_team/jinxs/utils/core/build.jinx,sha256=QrShGspHwP1z073334vhUIIJZ_3pMJWN_DX_DPPVslU,2771
63
+ npcsh/npc_team/jinxs/utils/core/compile.jinx,sha256=Rjdm5jf3ech1E3cnpLz-o2tbJuVvEoQGAp0FQRAU7qo,2526
64
+ npcsh/npc_team/jinxs/utils/core/help.jinx,sha256=OquhUEgcYZp-gu5Wgl3pOZnswxGQ96RoNG08tHjC9-4,2091
65
+ npcsh/npc_team/jinxs/utils/core/init.jinx,sha256=QBb1uOTvMlD-x3S7zPASH5TBZRwNhMQvK6t3DdC2mVw,1596
66
+ npcsh/npc_team/jinxs/utils/core/jinxs.jinx,sha256=rF432zHrVeccbGKm5tHxd_bZ7OQk355xB6LTlEIXiuI,1269
67
+ npcsh/npc_team/jinxs/utils/core/set.jinx,sha256=hQY_0muEtnWtfXsdK9cPwSvIevCimiJJn1-yhGC_VxM,1381
68
+ npcsh-1.1.6.data/data/npcsh/npc_team/alicanto.jinx,sha256=MknpYUX0eIvi5vG9gkoTkJvF_LcFbAp_hQ0qkYEBr3c,4014
69
+ npcsh-1.1.6.data/data/npcsh/npc_team/alicanto.npc,sha256=y9yDY3lq8ZwxQxpnrgle8w5IJwZqvxDepZFU4OaZCtg,148
70
+ npcsh-1.1.6.data/data/npcsh/npc_team/alicanto.png,sha256=A7xeMbcoKGjlkELxJEVifCEZLVWbOKZarTN5ZFJG-FM,3519858
71
+ npcsh-1.1.6.data/data/npcsh/npc_team/breathe.jinx,sha256=WDw13P3Q0M03HdZu-vqhbOhefLjaMZ5oUcct_W4kUsY,739
72
+ npcsh-1.1.6.data/data/npcsh/npc_team/build.jinx,sha256=QrShGspHwP1z073334vhUIIJZ_3pMJWN_DX_DPPVslU,2771
73
+ npcsh-1.1.6.data/data/npcsh/npc_team/compile.jinx,sha256=Rjdm5jf3ech1E3cnpLz-o2tbJuVvEoQGAp0FQRAU7qo,2526
74
+ npcsh-1.1.6.data/data/npcsh/npc_team/corca.jinx,sha256=OFzxSHoBJ2Yoc34mtTpd9B_CtGdqbpgcCN3Qt39YJeA,1028
75
+ npcsh-1.1.6.data/data/npcsh/npc_team/corca.npc,sha256=NtZW1mQ_AMOHlfMCfl8A3uA00UMuHuO95FzRg6kUixo,631
76
+ npcsh-1.1.6.data/data/npcsh/npc_team/corca.png,sha256=0lF70hKu6tY-37YmIPVF2cuaPzvnQ4-UtQOzuAbKEf4,1666776
77
+ npcsh-1.1.6.data/data/npcsh/npc_team/corca_example.png,sha256=p0lVTuwaps4-F-3k4wgp9d897YPyn6FGZugtXMUQjj8,28777
78
+ npcsh-1.1.6.data/data/npcsh/npc_team/edit_file.jinx,sha256=jExsHctvapG2xlze6E7ZR3oSLS9hJTYKKd41dQwgOLw,3488
79
+ npcsh-1.1.6.data/data/npcsh/npc_team/flush.jinx,sha256=ngzFu4-dnKkqqL0QM9iX9XBxyWOmQdVcJTFb1GhajVo,1422
80
+ npcsh-1.1.6.data/data/npcsh/npc_team/foreman.npc,sha256=WqB8jLfBToGmr8c1vip1KOnTHxfXlGXwDUGnZoDMQr0,327
81
+ npcsh-1.1.6.data/data/npcsh/npc_team/frederic.npc,sha256=EE2dOUItp-VKuW3ZMSHffmIEO4evjPcU2W_C4P3WXbY,362
82
+ npcsh-1.1.6.data/data/npcsh/npc_team/frederic4.png,sha256=ll8uoV0npnPp5HVJWv7h0xDSeuq4pqsk_gYGBHLS0VY,1590744
83
+ npcsh-1.1.6.data/data/npcsh/npc_team/guac.jinx,sha256=UIVXw8c-m-lh10bxL2yl2n94TQ_SjZSwLP3sLFGv0k4,1616
84
+ npcsh-1.1.6.data/data/npcsh/npc_team/guac.png,sha256=MCE7eJuEJwLJEzc9FS7lL62Mm-38jQRHkxXogPfOTuw,211470
85
+ npcsh-1.1.6.data/data/npcsh/npc_team/help.jinx,sha256=OquhUEgcYZp-gu5Wgl3pOZnswxGQ96RoNG08tHjC9-4,2091
86
+ npcsh-1.1.6.data/data/npcsh/npc_team/init.jinx,sha256=QBb1uOTvMlD-x3S7zPASH5TBZRwNhMQvK6t3DdC2mVw,1596
87
+ npcsh-1.1.6.data/data/npcsh/npc_team/jinxs.jinx,sha256=rF432zHrVeccbGKm5tHxd_bZ7OQk355xB6LTlEIXiuI,1269
88
+ npcsh-1.1.6.data/data/npcsh/npc_team/kadiefa.npc,sha256=Yl5a4wrfe4F2f6Ndw_ukzlVVX7NE9g_mG-3QqJSkg_o,381
89
+ npcsh-1.1.6.data/data/npcsh/npc_team/kadiefa.png,sha256=3CAwL8crKIwJko6o75Z6OYYEEM9Rk--yGzCJg7zoszg,3062528
90
+ npcsh-1.1.6.data/data/npcsh/npc_team/npc-studio.jinx,sha256=0aY-z399BRIXIL3TLMTcYDiHjDm-krZy0CnYfiskQUo,2234
91
+ npcsh-1.1.6.data/data/npcsh/npc_team/npcsh.ctx,sha256=-jKYaPm2YbZHAGgWAXhyPIwhiNe1H1ZRFg1Zc7tHSxk,1049
92
+ npcsh-1.1.6.data/data/npcsh/npc_team/npcsh_sibiji.png,sha256=9fUqgYMsSHmaH-kBTBQ7N5UCS5-eLZF94Log0O3mtFg,4544
93
+ npcsh-1.1.6.data/data/npcsh/npc_team/ots.jinx,sha256=5Dpsyf0h2M80mkdZnouMp1PSK9S0TCPrINRLoP_1tOc,2303
94
+ npcsh-1.1.6.data/data/npcsh/npc_team/plan.jinx,sha256=hCIG9nGI56C1SeGuGAUcR3XnJ25kHaDnUn1VCv8vszY,1234
95
+ npcsh-1.1.6.data/data/npcsh/npc_team/plonk.jinx,sha256=3f5MvkYBFh5Z3iDhs5vFxPT6acgw7OZLqVA-Mxtm_vc,2559
96
+ npcsh-1.1.6.data/data/npcsh/npc_team/plonk.npc,sha256=u1m2a1D512XGQ2kC3eWDAY8Y2IvpkNU73DI_CPE65UE,90
97
+ npcsh-1.1.6.data/data/npcsh/npc_team/plonk.png,sha256=IU5ey-Dl4HEKlwnf75RSWNSHpF8rVqGmdbsa0deL4rQ,2727773
98
+ npcsh-1.1.6.data/data/npcsh/npc_team/plonkjr.npc,sha256=It-i-BEuG0XddKk0d85onk2aJr9Pe5pLnJzNaCWaQIM,87
99
+ npcsh-1.1.6.data/data/npcsh/npc_team/plonkjr.png,sha256=MqLEGwsyECUeODZIti0HQQrMMVxA6XERpW01R06NbpY,2606710
100
+ npcsh-1.1.6.data/data/npcsh/npc_team/pti.jinx,sha256=Yw32GQS9LvYkukEfjq6R1GLAL6fWACYBz9JuVecZJEo,1126
101
+ npcsh-1.1.6.data/data/npcsh/npc_team/python.jinx,sha256=lFJubdPVlGxSuUKCxsxjYG4_dnX2ATn8U9ChYKRmL5Q,389
102
+ npcsh-1.1.6.data/data/npcsh/npc_team/roll.jinx,sha256=FHoqXXqFgucaW7UJW_14DcRcRlVPBgFeaPJPoATx5BY,2882
103
+ npcsh-1.1.6.data/data/npcsh/npc_team/sample.jinx,sha256=7cWwfAZFgWxaTkIL1gpFFryQ3mjvVjoWYAov-zOFn_E,2237
104
+ npcsh-1.1.6.data/data/npcsh/npc_team/search.jinx,sha256=7R37sElFo-XooRNKYqHaouQ-lOxmAxew_8uSXQfNP_Q,5421
105
+ npcsh-1.1.6.data/data/npcsh/npc_team/serve.jinx,sha256=qly_3MThU3TRyJI2grHlhYOqEY1VT-XxubPIuWdZrpU,1056
106
+ npcsh-1.1.6.data/data/npcsh/npc_team/set.jinx,sha256=hQY_0muEtnWtfXsdK9cPwSvIevCimiJJn1-yhGC_VxM,1381
107
+ npcsh-1.1.6.data/data/npcsh/npc_team/sh.jinx,sha256=Z_Cuok4FDUxuZGPCuqWS9D3TPI9SdkaZY4U_TCnie2g,666
108
+ npcsh-1.1.6.data/data/npcsh/npc_team/sibiji.npc,sha256=Hb4wXKIObKKgibwnio5hLec9yd_9bKDCA87Nm2zijFA,216
109
+ npcsh-1.1.6.data/data/npcsh/npc_team/sibiji.png,sha256=1dlZb7J3E62FcVo9CVOzLb8nu1bIUV7cr97nsFocHCM,35615
110
+ npcsh-1.1.6.data/data/npcsh/npc_team/sleep.jinx,sha256=c-7Dn4aLuX7WyBVcvuk3sqcbIutqKIz1N9sBfPNzhck,5301
111
+ npcsh-1.1.6.data/data/npcsh/npc_team/spool.jinx,sha256=A4upAI4LnXxYUjY0Rz1_kAhRCDpz08XWPTgisiH06A4,1664
112
+ npcsh-1.1.6.data/data/npcsh/npc_team/spool.png,sha256=LWTLkwDxXBfLuSUCX32_lo5yAmLYGsA67Xpsz-7MmWU,2876725
113
+ npcsh-1.1.6.data/data/npcsh/npc_team/sql.jinx,sha256=U3scchBO3tqCQRIErC-W87eLtiCv-YGmN7ftqyIvcVc,582
114
+ npcsh-1.1.6.data/data/npcsh/npc_team/trigger.jinx,sha256=rS913e2qJzNBC0wmmecgzN3f4v8o1os8AZQOPjnW8ho,1456
115
+ npcsh-1.1.6.data/data/npcsh/npc_team/vixynt.jinx,sha256=ECNE02omzgvJ2B8ZO8K6OylMa3lLGBNEEeFZ-oXiKC0,4070
116
+ npcsh-1.1.6.data/data/npcsh/npc_team/wander.jinx,sha256=Svc6zjmoXr4BbDg5SN4DB1Byhh75AmIeAItcJCBIlcc,3513
117
+ npcsh-1.1.6.data/data/npcsh/npc_team/yap.jinx,sha256=eaI665zjaLH2FUwHoO3iC1Uzo9bGA-a1UMtBRBTEHC0,898
118
+ npcsh-1.1.6.data/data/npcsh/npc_team/yap.png,sha256=_l7UbWnXJdsy4Mx-x5l9DT0R6ize3HTnkwQQnOFlI18,1548649
119
+ npcsh-1.1.6.dist-info/licenses/LICENSE,sha256=IKBvAECHP-aCiJtE4cHGCE5Yl0tozYz02PomGeWS3y4,1070
120
+ npcsh-1.1.6.dist-info/METADATA,sha256=0NId0-848netPd6jrN8mNJLSubodJpioYFJULXzehlw,25292
121
+ npcsh-1.1.6.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
122
+ npcsh-1.1.6.dist-info/entry_points.txt,sha256=S5yIuGm8ZXQ4siHYgN5gs0J7bxgobSEULXf8L5HaW5o,206
123
+ npcsh-1.1.6.dist-info/top_level.txt,sha256=kHSNgKMCkfjV95-DH0YSp1LLBi0HXdF3w57j7MQON3E,6
124
+ npcsh-1.1.6.dist-info/RECORD,,
@@ -1,29 +0,0 @@
1
- jinx_name: image_generation_jinx
2
- description: 'Generates images based on a text prompt. Prompt must be specified to facilitate the users goal and should NOT be a verbatim replication of their request unless asked. The output name must be a path relative to the current directory. do NOT use placeholders. specify ./descriptive_image_name.png. Model must be specified if the user indicates a specific model or provider. For example, if they want gemini-2.5-flash you should specify gemini-2.5-flash as the model and gemini as the provider . if they specify gpt-image-1 you should specify gpt-image-1 as the model and openai as the provider. Only leave it the default if the user does not indicate the model preference.'
3
- inputs:
4
- - prompt
5
- - output_name
6
- - model: runwayml/stable-diffusion-v1-5
7
- - provider: diffusers
8
- steps:
9
- - engine: "python"
10
- code: |
11
- image_prompt = '{{prompt}}'.strip()
12
- from npcpy.llm_funcs import gen_image
13
-
14
- pil_image = gen_image(
15
- image_prompt,
16
- npc=npc,
17
- model='{{model}}',
18
- provider='{{provider}}'
19
- )
20
- if pil_image:
21
- image_generated = True
22
- else:
23
- image_generated = False
24
-
25
- output_name = '{{output_name}}'
26
- pil_image.save(f'{output_name}.png')
27
-
28
-
29
- output = output_name
@@ -1,31 +0,0 @@
1
- jinx_name: internet_search
2
- description: Searches the web for information based on a query in order to verify
3
- timiely details (e.g. current events) or to corroborate information in uncertain
4
- situations. Should be mainly only used when users specifically request a search,
5
- otherwise an LLMs basic knowledge should be sufficient. The Query must be written specifically
6
- as a search query, it should not be a direct parroting of the user's input text. Returns a LLM summary so no post-summary is required
7
- inputs:
8
- - query
9
- - provider: ''
10
- steps:
11
- - engine: "python"
12
- code: |
13
- from npcpy.data.web import search_web
14
- from npcsh._state import NPCSH_SEARCH_PROVIDER
15
- query = "{{ query }}"
16
- provider = '{{ provider }}'
17
- if provider.strip() != '':
18
- results = search_web(query, num_results=5, provider = provider)
19
- else:
20
- results = search_web(query, num_results=5, provider = NPCSH_SEARCH_PROVIDER)
21
-
22
- print('QUERY in jinx', query)
23
- results = search_web(query, num_results=5, provider = NPCSH_SEARCH_PROVIDER)
24
- print('RESULTS in jinx', results)
25
- - engine: "natural"
26
- code: |
27
- Using the following information extracted from the web:
28
-
29
- {{ results }}
30
-
31
- Answer the users question: {{ query }}
@@ -1,43 +0,0 @@
1
- jinx_name: search_kg
2
- description: Search knowledge graph for relevant facts
3
- inputs:
4
- - query
5
- steps:
6
- - name: retrieve_facts
7
- engine: python
8
- code: |
9
- from npcpy.memory.command_history import load_kg_from_db
10
- import os
11
-
12
- kg = load_kg_from_db(
13
- command_history.engine,
14
- team.name if team else '__none__',
15
- npc.name if hasattr(npc, 'name') else '__none__',
16
- os.getcwd()
17
- )
18
-
19
- query_lower = '{{ query }}'.lower()
20
- matching_facts = []
21
-
22
- if kg and 'facts' in kg:
23
- for fact in kg['facts']:
24
- statement = fact.get('statement', '').lower()
25
- if query_lower in statement:
26
- matching_facts.append(fact)
27
-
28
- output = []
29
- for i, fact in enumerate(matching_facts[:10], 1):
30
- statement = fact.get('statement', '')
31
- fact_type = fact.get('type', 'unknown')
32
- output.append(f"{i}. [{fact_type}] {statement}")
33
-
34
- output = "\n".join(output) if output else "No facts found"
35
-
36
- - name: analyze_facts
37
- engine: natural
38
- code: |
39
- Knowledge graph facts for query "{{ query }}":
40
-
41
- {{ retrieve_facts }}
42
-
43
- Analyze how these facts relate to the query.
@@ -1,36 +0,0 @@
1
- jinx_name: search_memories
2
- description: Search through approved memories for relevant context
3
- inputs:
4
- - query
5
- steps:
6
- - name: retrieve_memories
7
- engine: python
8
- code: |
9
- from npcsh._state import get_relevant_memories
10
- import os
11
-
12
- memories = get_relevant_memories(
13
- command_history=command_history,
14
- npc_name=npc.name if hasattr(npc, 'name') else '__none__',
15
- team_name=team.name if team else '__none__',
16
- path=os.getcwd(),
17
- query='{{ query }}',
18
- max_memories=10,
19
- state=state
20
- )
21
-
22
- output = []
23
- for i, mem in enumerate(memories, 1):
24
- content = mem.get('final_memory', mem.get('initial_memory', ''))
25
- output.append(f"{i}. {content}")
26
-
27
- output = "\n".join(output) if output else "No memories found"
28
-
29
- - name: format_results
30
- engine: natural
31
- code: |
32
- Found memories for query "{{ query }}":
33
-
34
- {{ retrieve_memories }}
35
-
36
- Summarize the key points from these memories.
@@ -1,25 +0,0 @@
1
- jinx_name: screen_cap
2
- description: Captures the whole screen and sends the image for analysis
3
- inputs:
4
- - prompt
5
- steps:
6
- - engine: "python"
7
- code: |
8
- import os
9
- from npcpy.data.image import capture_screenshot
10
- out = capture_screenshot(full=True)
11
- prompt = "{{prompt}}"
12
-
13
-
14
- analysis_prompt = prompt + "\n\nAttached is a screenshot of my screen currently. Please use this to evaluate the situation. If the user asked for you to explain what's on their screen or something similar, they are referring to the details contained within the attached image."
15
- llm_response = get_llm_response(
16
- prompt=analysis_prompt,
17
- model=npc.model if npc else None,
18
- provider=npc.provider if npc else None,
19
- api_url=npc.api_url if npc else None,
20
- api_key=npc.api_key if npc else None,
21
- npc=npc,
22
- images=[out['file_path']],
23
- )
24
- output = llm_response['response']
25
-
@@ -1,29 +0,0 @@
1
- jinx_name: image_generation_jinx
2
- description: 'Generates images based on a text prompt. Prompt must be specified to facilitate the users goal and should NOT be a verbatim replication of their request unless asked. The output name must be a path relative to the current directory. do NOT use placeholders. specify ./descriptive_image_name.png. Model must be specified if the user indicates a specific model or provider. For example, if they want gemini-2.5-flash you should specify gemini-2.5-flash as the model and gemini as the provider . if they specify gpt-image-1 you should specify gpt-image-1 as the model and openai as the provider. Only leave it the default if the user does not indicate the model preference.'
3
- inputs:
4
- - prompt
5
- - output_name
6
- - model: runwayml/stable-diffusion-v1-5
7
- - provider: diffusers
8
- steps:
9
- - engine: "python"
10
- code: |
11
- image_prompt = '{{prompt}}'.strip()
12
- from npcpy.llm_funcs import gen_image
13
-
14
- pil_image = gen_image(
15
- image_prompt,
16
- npc=npc,
17
- model='{{model}}',
18
- provider='{{provider}}'
19
- )
20
- if pil_image:
21
- image_generated = True
22
- else:
23
- image_generated = False
24
-
25
- output_name = '{{output_name}}'
26
- pil_image.save(f'{output_name}.png')
27
-
28
-
29
- output = output_name
@@ -1,31 +0,0 @@
1
- jinx_name: internet_search
2
- description: Searches the web for information based on a query in order to verify
3
- timiely details (e.g. current events) or to corroborate information in uncertain
4
- situations. Should be mainly only used when users specifically request a search,
5
- otherwise an LLMs basic knowledge should be sufficient. The Query must be written specifically
6
- as a search query, it should not be a direct parroting of the user's input text. Returns a LLM summary so no post-summary is required
7
- inputs:
8
- - query
9
- - provider: ''
10
- steps:
11
- - engine: "python"
12
- code: |
13
- from npcpy.data.web import search_web
14
- from npcsh._state import NPCSH_SEARCH_PROVIDER
15
- query = "{{ query }}"
16
- provider = '{{ provider }}'
17
- if provider.strip() != '':
18
- results = search_web(query, num_results=5, provider = provider)
19
- else:
20
- results = search_web(query, num_results=5, provider = NPCSH_SEARCH_PROVIDER)
21
-
22
- print('QUERY in jinx', query)
23
- results = search_web(query, num_results=5, provider = NPCSH_SEARCH_PROVIDER)
24
- print('RESULTS in jinx', results)
25
- - engine: "natural"
26
- code: |
27
- Using the following information extracted from the web:
28
-
29
- {{ results }}
30
-
31
- Answer the users question: {{ query }}
@@ -1,43 +0,0 @@
1
- jinx_name: search_kg
2
- description: Search knowledge graph for relevant facts
3
- inputs:
4
- - query
5
- steps:
6
- - name: retrieve_facts
7
- engine: python
8
- code: |
9
- from npcpy.memory.command_history import load_kg_from_db
10
- import os
11
-
12
- kg = load_kg_from_db(
13
- command_history.engine,
14
- team.name if team else '__none__',
15
- npc.name if hasattr(npc, 'name') else '__none__',
16
- os.getcwd()
17
- )
18
-
19
- query_lower = '{{ query }}'.lower()
20
- matching_facts = []
21
-
22
- if kg and 'facts' in kg:
23
- for fact in kg['facts']:
24
- statement = fact.get('statement', '').lower()
25
- if query_lower in statement:
26
- matching_facts.append(fact)
27
-
28
- output = []
29
- for i, fact in enumerate(matching_facts[:10], 1):
30
- statement = fact.get('statement', '')
31
- fact_type = fact.get('type', 'unknown')
32
- output.append(f"{i}. [{fact_type}] {statement}")
33
-
34
- output = "\n".join(output) if output else "No facts found"
35
-
36
- - name: analyze_facts
37
- engine: natural
38
- code: |
39
- Knowledge graph facts for query "{{ query }}":
40
-
41
- {{ retrieve_facts }}
42
-
43
- Analyze how these facts relate to the query.