signalwire-agents 0.1.51__py3-none-any.whl → 0.1.54__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.
@@ -18,7 +18,7 @@ A package for building AI agents using SignalWire's AI and SWML capabilities.
18
18
  from .core.logging_config import configure_logging
19
19
  configure_logging()
20
20
 
21
- __version__ = "0.1.51"
21
+ __version__ = "0.1.54"
22
22
 
23
23
  # Import core classes for easier access
24
24
  from .core.agent_base import AgentBase
@@ -69,6 +69,16 @@ Examples:
69
69
  sw-search ./docs \\
70
70
  --chunking-strategy qa
71
71
 
72
+ # Markdown-aware chunking (preserves headers, detects code blocks, adds tags)
73
+ sw-search ./docs \\
74
+ --chunking-strategy markdown \\
75
+ --file-types md
76
+ # This strategy:
77
+ # - Chunks at header boundaries (h1, h2, h3...)
78
+ # - Detects code blocks and extracts language (python, bash, etc)
79
+ # - Adds "code" tags to chunks with code for better search
80
+ # - Preserves section hierarchy in metadata
81
+
72
82
  # Model selection examples (performance vs quality tradeoff)
73
83
  sw-search ./docs --model mini # Fastest (~5x faster), 384 dims, good for most use cases
74
84
  sw-search ./docs --model base # Balanced speed/quality, 768 dims (previous default)
@@ -128,16 +138,23 @@ Examples:
128
138
  --collection-name docs_collection
129
139
  sw-search migrate --info ./docs.swsearch
130
140
 
131
- # PostgreSQL pgvector backend
141
+ # PostgreSQL pgvector backend (direct build to PostgreSQL)
132
142
  sw-search ./docs \\
133
143
  --backend pgvector \\
134
- --connection-string "postgresql://user:pass@localhost/knowledge" \\
144
+ --connection-string "postgresql://user:pass@localhost:5432/knowledge" \\
135
145
  --output docs_collection
136
146
 
147
+ # pgvector with markdown strategy (best for documentation with code examples)
148
+ sw-search ./docs \\
149
+ --backend pgvector \\
150
+ --connection-string "postgresql://user:pass@localhost:5432/knowledge" \\
151
+ --output docs_collection \\
152
+ --chunking-strategy markdown
153
+
137
154
  # Overwrite existing pgvector collection
138
155
  sw-search ./docs \\
139
156
  --backend pgvector \\
140
- --connection-string "postgresql://user:pass@localhost/knowledge" \\
157
+ --connection-string "postgresql://user:pass@localhost:5432/knowledge" \\
141
158
  --output docs_collection \\
142
159
  --overwrite
143
160
 
@@ -191,9 +208,9 @@ Examples:
191
208
 
192
209
  parser.add_argument(
193
210
  '--chunking-strategy',
194
- choices=['sentence', 'sliding', 'paragraph', 'page', 'semantic', 'topic', 'qa', 'json'],
211
+ choices=['sentence', 'sliding', 'paragraph', 'page', 'semantic', 'topic', 'qa', 'json', 'markdown'],
195
212
  default='sentence',
196
- help='Chunking strategy to use (default: sentence)'
213
+ help='Chunking strategy to use (default: sentence). Use "markdown" for documentation with code blocks.'
197
214
  )
198
215
 
199
216
  parser.add_argument(