newo 2.0.6 → 3.1.0

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 (63) hide show
  1. package/CHANGELOG.md +338 -224
  2. package/README.md +257 -0
  3. package/dist/api.d.ts +23 -1
  4. package/dist/api.js +114 -0
  5. package/dist/auth.js +4 -0
  6. package/dist/cli/commands/create-agent.d.ts +3 -0
  7. package/dist/cli/commands/create-agent.js +75 -0
  8. package/dist/cli/commands/create-attribute.d.ts +3 -0
  9. package/dist/cli/commands/create-attribute.js +63 -0
  10. package/dist/cli/commands/create-event.d.ts +3 -0
  11. package/dist/cli/commands/create-event.js +66 -0
  12. package/dist/cli/commands/create-flow.d.ts +3 -0
  13. package/dist/cli/commands/create-flow.js +100 -0
  14. package/dist/cli/commands/create-parameter.d.ts +3 -0
  15. package/dist/cli/commands/create-parameter.js +47 -0
  16. package/dist/cli/commands/create-persona.d.ts +3 -0
  17. package/dist/cli/commands/create-persona.js +43 -0
  18. package/dist/cli/commands/create-project.d.ts +3 -0
  19. package/dist/cli/commands/create-project.js +55 -0
  20. package/dist/cli/commands/create-skill.d.ts +3 -0
  21. package/dist/cli/commands/create-skill.js +115 -0
  22. package/dist/cli/commands/create-state.d.ts +3 -0
  23. package/dist/cli/commands/create-state.js +58 -0
  24. package/dist/cli/commands/delete-agent.d.ts +3 -0
  25. package/dist/cli/commands/delete-agent.js +70 -0
  26. package/dist/cli/commands/delete-flow.d.ts +3 -0
  27. package/dist/cli/commands/delete-flow.js +83 -0
  28. package/dist/cli/commands/delete-skill.d.ts +3 -0
  29. package/dist/cli/commands/delete-skill.js +87 -0
  30. package/dist/cli/commands/help.js +114 -22
  31. package/dist/cli/commands/push.js +4 -3
  32. package/dist/cli/commands/sandbox.d.ts +14 -0
  33. package/dist/cli/commands/sandbox.js +306 -0
  34. package/dist/cli.js +57 -0
  35. package/dist/sandbox/chat.d.ts +40 -0
  36. package/dist/sandbox/chat.js +280 -0
  37. package/dist/sync/push.d.ts +1 -1
  38. package/dist/sync/push.js +372 -4
  39. package/dist/sync/status.js +178 -1
  40. package/dist/types.d.ts +181 -1
  41. package/package.json +6 -3
  42. package/src/api.ts +172 -1
  43. package/src/auth.ts +7 -2
  44. package/src/cli/commands/create-agent.ts +96 -0
  45. package/src/cli/commands/create-attribute.ts +75 -0
  46. package/src/cli/commands/create-event.ts +79 -0
  47. package/src/cli/commands/create-flow.ts +124 -0
  48. package/src/cli/commands/create-parameter.ts +59 -0
  49. package/src/cli/commands/create-persona.ts +54 -0
  50. package/src/cli/commands/create-project.ts +66 -0
  51. package/src/cli/commands/create-skill.ts +144 -0
  52. package/src/cli/commands/create-state.ts +71 -0
  53. package/src/cli/commands/delete-agent.ts +90 -0
  54. package/src/cli/commands/delete-flow.ts +105 -0
  55. package/src/cli/commands/delete-skill.ts +110 -0
  56. package/src/cli/commands/help.ts +114 -22
  57. package/src/cli/commands/push.ts +5 -3
  58. package/src/cli/commands/sandbox.ts +365 -0
  59. package/src/cli.ts +71 -0
  60. package/src/sandbox/chat.ts +339 -0
  61. package/src/sync/push.ts +413 -5
  62. package/src/sync/status.ts +183 -1
  63. package/src/types.ts +220 -2
package/CHANGELOG.md CHANGED
@@ -2,305 +2,389 @@
2
2
 
3
3
  All notable changes to this project will be documented in this file.
4
4
 
5
- The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
5
+ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/),
6
6
  and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
7
7
 
8
+ ## [Unreleased]
9
+
10
+ ## [3.1.0] - 2025-10-15
11
+
12
+ ### Added
13
+
14
+ - **Sandbox Chat Testing**: Real-time agent testing with interactive sandbox mode
15
+ - `newo sandbox "<message>"` - Single-command mode for automated testing workflows
16
+ - `newo sandbox --actor <id> "message"` - Multi-turn conversation continuation
17
+ - Automatic persona/actor creation with unique naming (`newo-cli-{guid}`)
18
+ - Chat History API polling with 1-second intervals, 60-second timeout
19
+ - Debug information extraction (flow_idn, skill_idn, session_id, runtime_context_id)
20
+ - Quiet mode (`--quiet`/`-q`) for script-friendly output with minimal logging
21
+ - Single newest message display to avoid overwhelming output
22
+ - **Sandbox API Integration**: 6 new endpoints for sandbox chat functionality
23
+ - `GET /api/v1/integrations` - List available integrations
24
+ - `GET /api/v1/integrations/{id}/connectors` - List integration connectors
25
+ - `POST /api/v1/customer/personas` - Create user persona for sandbox testing
26
+ - `POST /api/v1/customer/personas/{id}/actors` - Create actor (chat session)
27
+ - `POST /api/v1/chat/user/{actorId}` - Send chat message
28
+ - Reused `GET /api/v1/chat/history` - Poll for agent responses with timestamp filtering
29
+ - **Sandbox Utilities Module** (`src/sandbox/chat.ts`):
30
+ - `findSandboxConnector()` - Locate running sandbox connectors
31
+ - `createChatSession()` - Initialize new chat sessions with unique personas
32
+ - `sendMessage()` - Send messages with timestamp tracking for response filtering
33
+ - `pollForResponse()` - Intelligent polling with timestamp-based message filtering
34
+ - `extractAgentMessages()` - Filter and extract agent responses from chat history
35
+ - `formatDebugInfo()` - Format debug information for developer inspection
36
+ - **TypeScript Types**: Comprehensive type definitions for sandbox functionality
37
+ - `Integration`, `Connector` - Integration and connector management
38
+ - `SandboxChatSession` - Session state tracking with persona/actor IDs
39
+ - `ChatDebugInfo` - Debug information structure for agent development
40
+ - `CreateSandboxPersonaRequest/Response` - Persona creation types
41
+ - `CreateActorRequest/Response` - Actor creation types
42
+ - `SendChatMessageRequest` - Chat message sending types
43
+ - **Enhanced Authentication**: Quiet mode support to suppress logging during automated testing
44
+ - **Documentation**: Comprehensive sandbox testing section with usage examples and automation patterns
45
+
46
+ ### Changed
47
+
48
+ - **CLI Architecture**: Added sandbox command routing in main CLI module
49
+ - **API Module**: Extended with sandbox-specific endpoint integrations
50
+ - **Help Command**: Updated with sandbox command reference
51
+ - **README**: Added extensive sandbox testing documentation with multi-turn examples (+101 lines)
52
+
53
+ ### Technical Details
54
+
55
+ - **Message Filtering**: Timestamp-based filtering ensures only new messages shown after user sends message
56
+ - **Session Isolation**: Each sandbox test creates unique persona with GUID to prevent state interference
57
+ - **Polling Strategy**: 1-second intervals with 60-second max wait for agent responses
58
+ - **Error Handling**: Graceful degradation with timeout messages and continuation guidance
59
+ - **Debug Modes**: Standard (condensed) and verbose (detailed) debug information display
60
+ - **Quiet Mode**: Minimal output perfect for shell scripts and CI/CD integration
61
+
62
+ ### Example Usage
63
+
64
+ ```bash
65
+ # Start new conversation
66
+ newo sandbox "Hello, I want to order pizza"
67
+
68
+ # Continue conversation with actor ID from previous response
69
+ newo sandbox --actor abc123... "I want 2 large pepperoni pizzas"
70
+
71
+ # Verbose mode for debugging
72
+ newo sandbox "Test message" --verbose
73
+
74
+ # Quiet mode for automation
75
+ newo sandbox "Test query" --quiet
76
+ ```
77
+
78
+ ## [3.0.0] - 2025-09-29
79
+
80
+ ### Added
81
+
82
+ - **Entity Creation Commands**: 12 new commands for creating NEWO entities locally
83
+ - `newo create-project <idn>` - Create new projects on platform
84
+ - `newo create-persona <name>` - Create agent personas
85
+ - `newo create-attribute <idn>` - Create customer attributes
86
+ - `newo create-agent <idn> --project <pid>` - Create agents locally with metadata
87
+ - `newo create-flow <idn> --agent <aid>` - Create flows with guidance/NSL runner selection
88
+ - `newo create-skill <idn> --flow <fid>` - Create skills with script content initialization
89
+ - `newo create-event <idn> --flow <fid>` - Create flow events for integrations
90
+ - `newo create-state <idn> --flow <fid>` - Create flow state fields (user/flow/global scope)
91
+ - `newo create-parameter <name> --skill <sid>` - Create skill parameters
92
+ - **Entity Deletion Commands**: 3 new commands with confirmation flags
93
+ - `newo delete-agent <aid> --confirm` - Delete agent locally
94
+ - `newo delete-flow <fid> --confirm` - Delete flow locally
95
+ - `newo delete-skill <sid> --confirm` - Delete skill locally
96
+ - **API Integrations**: 19 new endpoints for entity creation, deletion, and publishing
97
+ - **Documentation**: Entity Management Commands section with workflows and examples (+146 lines)
98
+ - **TypeScript Types**: 19 new type definitions for entity operations
99
+
100
+ ### Changed
101
+
102
+ - **Push Command**: Now automatically detects and creates local-only entities on platform
103
+ - Filesystem scanning for entities not yet in project map
104
+ - Creates missing entities in correct hierarchical order (agent → flow → skill)
105
+ - Publishes flows after creation
106
+ - **Status Command**: Enhanced with comprehensive change detection
107
+ - Scans for local-only entities not yet on platform
108
+ - Reports new agents/flows/skills awaiting sync
109
+ - Hierarchical display of project structure
110
+ - **Architecture**: Added 14 new command modules in src/cli/commands/
111
+ - **Push Module**: Enhanced with local-only entity scanning (~418 lines)
112
+ - **Status Module**: Enhanced with entity detection (~184 lines)
113
+
114
+ ## [2.0.6] - 2025-09-18
115
+
116
+ ### Changed
117
+
118
+ - Implement proper LCS-based diff algorithm for accurate change detection
119
+ - Clean, accurate differences with proper line matching
120
+ - Improved algorithm eliminates false positives and shows precise modifications
121
+
122
+ ## [2.0.5] - 2025-09-18
123
+
124
+ ### Fixed
125
+
126
+ - Correct diff algorithm to show clean, accurate differences
127
+ - Improved change detection with proper context preservation
128
+
129
+ ## [2.0.4] - 2025-09-18
130
+
131
+ ### Changed
132
+
133
+ - Implement exact GitHub diff format with proper context lines
134
+ - GitHub-style diff with background colors and context
135
+ - Enhanced diff display with line numbers and clearer messaging
136
+
137
+ ## [2.0.3] - 2025-09-18
138
+
139
+ ### Changed
140
+
141
+ - Improve diff display with line numbers and clearer messaging
142
+ - Better visual distinction for changes with colored output
143
+
144
+ ## [2.0.2] - 2025-09-18
145
+
146
+ ### Added
147
+
148
+ - GitHub-style colored diff display for overwrite prompts
149
+ - Enhanced diff visualization with colors and formatting
150
+
151
+ ## [2.0.1] - 2025-09-18
152
+
153
+ ### Fixed
154
+
155
+ - Improve overwrite handling with proper 'all' option support
156
+ - Better handling of batch overwrite operations
157
+
8
158
  ## [1.9.3] - 2025-09-17
9
159
 
10
- ### 🏗️ Major Architecture Refactoring
160
+ ### Changed
11
161
 
12
- **CLI Module Restructuring:**
13
162
  - **BREAKING**: Main CLI entry point moved from `dist/cli.js` to `dist/cli/index.js`
14
- - Split monolithic 500+ line `cli.ts` into focused modules:
163
+ - Split monolithic 500+ line `cli.ts` into focused modules
15
164
  - `cli/index.ts` - Main entry point and command routing
16
- - `cli/errors.ts` - Centralized error handling with user-friendly messages
17
- - `cli/customer-selection.ts` - Customer management and selection logic
18
- - `cli/commands/` - Individual command handlers (pull, push, status, conversations, etc.)
19
-
20
- **Sync Module Restructuring:**
21
- - Extracted key functions from 1400+ line `sync.ts` into focused modules:
165
+ - `cli/errors.ts` - Centralized error handling
166
+ - `cli/customer-selection.ts` - Customer management logic
167
+ - `cli/commands/` - Individual command handlers
168
+ - Extracted key functions from 1400+ line `sync.ts` into focused modules
22
169
  - `sync/attributes.ts` - Customer attributes synchronization
23
170
  - `sync/conversations.ts` - Conversation history management
24
171
  - `sync/status.ts` - File status checking and change detection
25
172
  - `sync/index.ts` - Unified exports with backward compatibility
26
-
27
- **Testing Infrastructure:**
28
- - Fixed all test imports to use compiled JavaScript from `dist/` directory
29
- - Converted test utilities from CommonJS to ES modules
30
- - Improved test isolation and ES module compatibility
31
-
32
- ### 🔧 Technical Improvements
33
- - **Maintainability**: Single-responsibility modules with clear interfaces
34
- - **Testability**: Each module can be tested independently with clear dependencies
35
- - **Readability**: Focused modules replace hard-to-navigate monolithic files
36
- - **Extensibility**: Easy to add new commands and sync operations
37
- - **Type Safety**: Enhanced TypeScript compilation with zero errors
38
-
39
- ### 📚 Documentation Updates
40
173
  - Updated CLAUDE.md with new modular architecture documentation
41
- - Added comprehensive module descriptions and benefits
42
- - Updated development patterns for the new structure
43
174
 
44
- ## [2.0.0] - 2025-09-17
45
-
46
- ### 🚀 Major Release: Professional Modular Architecture
47
-
48
- **BREAKING CHANGES**
49
- - **IDN-Based File Naming**: Skills now saved as `{skillIdn}.jinja/.guidance` instead of `skill.jinja/.guidance`
50
- - **Automatic Migration**: Existing files automatically renamed to IDN format during pull
51
- - **Enhanced File Validation**: Multiple script files per skill now generate warnings and block push operations
52
-
53
- ### 🏗️ Complete Architecture Refactoring
175
+ ### Fixed
54
176
 
55
- **CLI Module Restructuring:**
56
- - **Entry Point**: `src/cli.ts` (124 lines) - Clean main entry using modular imports
57
- - **Error Handling**: `src/cli/errors.ts` - Centralized error management with user-friendly messages
58
- - **Customer Management**: `src/cli/customer-selection.ts` - Reusable customer selection logic
59
- - **Command Handlers**: `src/cli/commands/` - Individual handlers for all commands
177
+ - Test imports to use compiled JavaScript from `dist/` directory
178
+ - Test utilities converted from CommonJS to ES modules
179
+ - Improved test isolation and ES module compatibility
60
180
 
61
- **Sync Module Restructuring:**
62
- - **Entry Point**: `src/sync.ts` (13 lines) - Unified exports with re-exports
63
- - **Projects**: `src/sync/projects.ts` - Project sync with progress tracking and IDN naming
64
- - **Push Operations**: `src/sync/push.ts` - File validation and upload with multiple file detection
65
- - **Status Checking**: `src/sync/status.ts` - Change detection with file validation warnings
66
- - **Attributes**: `src/sync/attributes.ts` - Customer attributes synchronization
67
- - **Conversations**: `src/sync/conversations.ts` - Conversation history management
68
- - **Metadata**: `src/sync/metadata.ts` - flows.yaml generation (clean, no prompt_script)
69
- - **File Utilities**: `src/sync/skill-files.ts` - IDN-based naming and validation
181
+ ## [2.0.0] - 2025-09-17
70
182
 
71
- ### 🎯 Enhanced User Experience
183
+ ### Added
72
184
 
73
- **Progress Tracking:**
185
+ - IDN-based skill file naming for easy identification
74
186
  - Real-time progress display during large operations (966+ skills)
75
187
  - Percentage completion with skill counts
76
- - Clean progress updates every 10 processed skills
77
- - Clear completion confirmations
188
+ - Multiple file detection with clear warnings
189
+ - Force mode with `--force/-f` flag for silent operations
190
+ - Complete metadata.yaml hierarchy at all levels
78
191
 
79
- **IDN-Based File Management:**
80
- - Skills named after their IDN for easy identification
192
+ ### Changed
193
+
194
+ - **BREAKING**: Skills now saved as `{skillIdn}.jinja/.guidance` instead of `skill.jinja/.guidance`
195
+ - **BREAKING**: Existing files automatically renamed to IDN format during pull
196
+ - Refactored CLI module structure
197
+ - `src/cli.ts` (124 lines) - Clean main entry using modular imports
198
+ - `src/cli/errors.ts` - Centralized error management
199
+ - `src/cli/customer-selection.ts` - Reusable customer selection logic
200
+ - `src/cli/commands/` - Individual handlers for all commands
201
+ - Refactored sync module structure
202
+ - `src/sync.ts` (13 lines) - Unified exports with re-exports
203
+ - `src/sync/projects.ts` - Project sync with progress tracking
204
+ - `src/sync/push.ts` - File validation and upload
205
+ - `src/sync/status.ts` - Change detection with file validation
206
+ - `src/sync/attributes.ts` - Customer attributes synchronization
207
+ - `src/sync/conversations.ts` - Conversation history management
208
+ - `src/sync/metadata.ts` - flows.yaml generation (removed prompt_script)
209
+ - `src/sync/skill-files.ts` - IDN-based naming and validation
81
210
  - Flexible file discovery (any .jinja/.guidance/.nsl file)
82
211
  - Smart overwrite detection (content-based, not filename-based)
83
- - Force mode with `--force/-f` flag for silent operations
212
+ - Complete hash coverage for flows.yaml and attributes.yaml
213
+ - Zero TypeScript compilation errors with strict typing
214
+ - Modular loading with reduced memory footprint
84
215
 
85
- **Enhanced Validation:**
86
- - Multiple file detection with clear warnings
87
- - Safe push operations that skip problematic skills
88
- - Actionable error messages with resolution guidance
89
- - Clean status display with file-level change detection
216
+ ### Fixed
90
217
 
91
- ### 🔧 Technical Excellence
218
+ - False positive change detection
219
+ - Status now shows "Clean." immediately after pull operations
220
+ - Safe push operations that skip problematic skills with multiple files
92
221
 
93
- **Hash Consistency:**
94
- - Complete hash coverage for flows.yaml and attributes.yaml
95
- - No false positive change detection
96
- - Status shows "Clean." immediately after pull operations
97
- - Consistent hash tracking across all generated files
222
+ ## [1.9.2] - 2025-09-16
98
223
 
99
- **File Structure Optimization:**
100
- - flows.yaml cleanup (removed prompt_script content)
101
- - Automatic attributes.yaml generation during pull
102
- - Complete metadata.yaml hierarchy at all levels
103
- - IDN-based skill folder organization
224
+ ### Added
104
225
 
105
- **Performance & Quality:**
106
- - Zero TypeScript compilation errors with strict typing
107
- - Modular loading with reduced memory footprint
108
- - Efficient API calls and file operations
109
- - Professional error handling and user guidance
110
-
111
- ### 📚 Comprehensive Testing Results
112
-
113
- **All Functions Validated:**
114
- - ✅ Pull: 966/944 skills processed with perfect progress tracking
115
- - ✅ Status: Accurate change detection and clean state validation
116
- - ✅ Push: Successful uploads with smart file validation
117
- - ✅ Multi-customer: Independent customer operations working correctly
118
- - ✅ Attributes: Automatic 230KB+ attributes.yaml generation
119
- - ✅ Conversations: Working conversation history extraction
120
- - ✅ AKB Import: Proper parsing and validation (2 articles parsed)
121
- - ✅ Error Handling: Clear, actionable messages for all scenarios
122
- - ✅ File Validation: Multiple file warnings and safe skipping
226
+ - Max pages limit (50 pages = 5000 acts per persona) to prevent infinite pagination
227
+ - Verbose logging for pagination progress
123
228
 
124
- ## [1.9.2] - 2025-09-16
229
+ ### Changed
230
+
231
+ - Skip personas without newo_voice actors immediately for better performance
232
+ - Optimized control flow to prevent hanging during large conversation extraction
125
233
 
126
234
  ### Fixed
127
- - **Pagination Safety**: Prevent infinite loops and hanging during conversation processing
128
- - Added max pages limit (50 pages = 5000 acts per persona) to prevent infinite pagination
129
- - Improved persona filtering for voice actors to avoid unnecessary API calls
130
- - Better error handling and verbose logging for debugging conversation processing
131
- - Graceful handling of personas without voice actors (adds with empty acts array)
132
235
 
133
- ### Enhanced
134
- - **Performance Optimization**: Faster conversation processing with early exits
135
- - Skip personas without newo_voice actors immediately
136
- - Clear verbose logging for pagination progress
137
- - Optimized control flow to prevent hanging during large conversation extraction
236
+ - Infinite loops during conversation processing
237
+ - Improved persona filtering for voice actors
238
+ - Graceful handling of personas without voice actors
138
239
 
139
240
  ## [1.9.1] - 2025-09-16
140
241
 
141
- ### Fixed
142
- - **Clean Chat History Implementation**: Remove conversations acts API fallback entirely
143
- - Eliminates all 403 "Invalid token or account_id field missing" errors
144
- - Uses only `/api/v1/chat/history` endpoint which works with current API keys
145
- - Removed unused `getConversationActs()` function and related types
146
- - Clean implementation without permission-dependent fallbacks
147
-
148
242
  ### Removed
149
- - **Obsolete Code Cleanup**: Remove unused conversation acts API components
150
- - `getConversationActs()` function (unused after chat history integration)
151
- - `ConversationActsParams` and `ConversationActsResponse` interfaces
152
- - Fallback logic that caused 403 errors for personas without proper permissions
243
+
244
+ - Conversations acts API fallback (eliminates 403 errors)
245
+ - `getConversationActs()` function (unused after chat history integration)
246
+ - `ConversationActsParams` and `ConversationActsResponse` interfaces
247
+ - Fallback logic that caused 403 errors for personas without proper permissions
248
+
249
+ ### Changed
250
+
251
+ - Use only `/api/v1/chat/history` endpoint which works with current API keys
153
252
 
154
253
  ## [1.9.0] - 2025-09-16
155
254
 
156
255
  ### Added
157
- - **User Conversations Pull Functionality**: Complete conversation history extraction
158
- - New `newo conversations` command to download user conversations and personas
159
- - Multi-customer conversation support with `--customer <idn>` flag
160
- - Chat History API integration (`/api/v1/chat/history`) with fallback to conversations acts API
161
- - Automatic phone number extraction from persona actors
162
- - Comprehensive pagination handling for large conversation datasets
163
- - Clean YAML output format in `newo_customers/{customerIdn}/conversations.yaml`
164
256
 
165
- ### Enhanced
166
- - **Conversation Data Processing**: Optimized structure and chronological ordering
167
- - Acts sorted by datetime ascending (chronological conversation flow)
168
- - Personas sorted by most recent activity (descending)
169
- - Redundant fields removed (`is_agent`, `session_id: unknown`, etc.)
170
- - Clean persona structure: `id` `name` → `phone` → `act_count` → `acts`
171
- - Proper datetime extraction from chat history API responses
172
-
173
- ### Technical
174
- - **New API Functions**: Type-safe conversation API integration
257
+ - `newo conversations` command to download user conversations and personas
258
+ - Multi-customer conversation support with `--customer <idn>` flag
259
+ - Chat History API integration (`/api/v1/chat/history`) with fallback support
260
+ - Automatic phone number extraction from persona actors
261
+ - Comprehensive pagination handling for large conversation datasets
262
+ - Clean YAML output format in `newo_customers/{customerIdn}/conversations.yaml`
263
+ - Type-safe conversation API integration
175
264
  - `listUserPersonas()` - Get all user personas with pagination
176
265
  - `getChatHistory()` - Get conversation history for user actors
177
266
  - `getConversationActs()` - Fallback for accounts with proper permissions
178
267
  - `pullConversations()` - Complete conversation sync orchestration
179
- - **NPM Scripts**: Added convenient conversation commands
180
- - `npm run conversations` - Build and pull conversations
181
- - `npm run conversations:all` - Legacy alias for compatibility
268
+ - NPM scripts: `npm run conversations` and `npm run conversations:all`
269
+
270
+ ### Changed
182
271
 
183
- ### Performance
184
- - **Concurrent Processing**: Efficient conversation data extraction
185
- - Parallel API calls with concurrency limiting (p-limit)
186
- - Graceful error handling with persona-level fault tolerance
187
- - No artificial limits on personas or acts (loads all available data)
188
- - Multi-customer support with authentication reuse
272
+ - Acts sorted by datetime ascending (chronological conversation flow)
273
+ - Personas sorted by most recent activity (descending)
274
+ - Clean persona structure: `id` `name` → `phone` → `act_count` → `acts`
275
+ - Parallel API calls with concurrency limiting (p-limit)
276
+ - Graceful error handling with persona-level fault tolerance
277
+
278
+ ### Removed
279
+
280
+ - Redundant fields (`is_agent`, `session_id: unknown`, etc.)
189
281
 
190
282
  ## [1.8.0] - 2025-09-15
191
283
 
192
284
  ### Added
193
- - **Complete Metadata Change Tracking**: Comprehensive metadata.yaml file synchronization
194
- - All metadata.yaml files now tracked with hash-based change detection
195
- - Status command shows detailed metadata changes (title, runner_type, model)
196
- - Push command automatically updates skills when metadata changes
197
- - flows.yaml automatically regenerated when metadata changes detected
198
- - Preserves flows.yaml format consistency with backup/comparison system
199
285
 
200
- ### Enhanced
201
- - **Comprehensive File Synchronization**: All NEWO workspace files fully tracked
202
- - Skills: .guidance and .jinja script files with hash tracking ✓
203
- - Metadata: metadata.yaml files with skill updates + flows.yaml regeneration ✓
204
- - Attributes: attributes.yaml with diff-based sync for 233 customer attributes ✓
205
- - Flows: flows.yaml with automatic regeneration and format preservation ✓
206
- - Multi-customer: All file types synchronized across multiple customer workspaces ✓
207
-
208
- ### Technical
209
- - **flows.yaml Regeneration**: Automatic regeneration pipeline when metadata changes
210
- - Creates backup before regeneration for format comparison
211
- - Re-fetches project data to ensure accuracy
212
- - Updates hash tracking for regenerated flows.yaml
213
- - Maintains consistent YAML format structure
286
+ - Complete metadata.yaml file synchronization with hash-based change detection
287
+ - Status command shows detailed metadata changes (title, runner_type, model)
288
+ - Push command automatically updates skills when metadata changes
289
+ - Automatic flows.yaml regeneration when metadata changes detected
290
+ - flows.yaml backup/comparison system for format preservation
291
+
292
+ ### Changed
293
+
294
+ - All NEWO workspace files fully tracked
295
+ - Skills: .guidance and .jinja script files with hash tracking
296
+ - Metadata: metadata.yaml files with skill updates + flows.yaml regeneration
297
+ - Attributes: attributes.yaml with diff-based sync for 233 customer attributes
298
+ - Flows: flows.yaml with automatic regeneration and format preservation
299
+ - Multi-customer: All file types synchronized across multiple customer workspaces
300
+ - Automatic regeneration pipeline creates backup before regeneration
301
+ - Re-fetches project data to ensure accuracy
302
+ - Maintains consistent YAML format structure
214
303
 
215
304
  ## [1.7.3] - 2025-09-15
216
305
 
217
306
  ### Added
218
- - **Complete Attributes Change Tracking**: Full hash-based change detection for customer attributes
219
- - Attributes.yaml files now included in hash tracking during pull operations
220
- - Status command detects and reports modifications to attributes.yaml files
221
- - Push command detects and handles attributes changes with proper synchronization
222
- - Comprehensive workflow: modify → status shows change → push applies change → status shows clean
223
307
 
224
- ### Enhanced
225
- - **File Synchronization Scope**: Extended to cover all file types in NEWO workspace
226
- - Skills: .guidance and .jinja files with full hash tracking ✓
227
- - Attributes: customer attributes.yaml with change detection ✓
228
- - Metadata: flows.yaml and metadata.yaml files tracked ✓
229
- - Multi-customer: all file types synchronized across multiple customers ✓
308
+ - Full hash-based change detection for customer attributes
309
+ - Attributes.yaml files included in hash tracking during pull operations
310
+ - Status command detects and reports modifications to attributes.yaml files
311
+ - Push command handles attributes changes with proper synchronization
312
+
313
+ ### Changed
314
+
315
+ - Extended file synchronization scope to all NEWO workspace file types
316
+ - Skills: .guidance and .jinja files with full hash tracking
317
+ - Attributes: customer attributes.yaml with change detection
318
+ - Metadata: flows.yaml and metadata.yaml files tracked
319
+ - Multi-customer: all file types synchronized across multiple customers
230
320
 
231
321
  ## [1.7.2] - 2025-09-15
232
322
 
323
+ ### Added
324
+
325
+ - `attributes.yaml` file tracking with modification times and sizes
326
+ - `flows.yaml` file tracking and statistics
327
+ - Comprehensive file monitoring across entire project structure
328
+
233
329
  ### Fixed
234
- - **YAML Enum Parsing**: Fixed attributes push check error with `!enum` format
235
- - Changed from YAML parsing to file stats for change detection
236
- - Prevents parsing errors with custom enum format in attributes.yaml
237
- - Maintains functionality while avoiding format conflicts
238
330
 
239
- ### Enhanced
240
- - **Status Command Scope**: Extended status checking to include all file types
241
- - Now tracks `attributes.yaml` files with modification times and sizes
242
- - Added `flows.yaml` file tracking and statistics
243
- - Comprehensive file monitoring across entire project structure
244
- - Better visibility into all managed files
331
+ - Attributes push check error with `!enum` format
332
+ - Changed from YAML parsing to file stats for change detection
333
+ - Prevents parsing errors with custom enum format in attributes.yaml
245
334
 
246
335
  ## [1.7.1] - 2025-09-15
247
336
 
248
- ### Enhanced
249
- - **Multi-Customer Commands**: Improved user experience for multi-customer operations
250
- - `newo status` now automatically checks all customers when no default is specified
251
- - `newo push` provides interactive customer selection dialog when multiple customers exist
252
- - No more error messages for commands that support multi-customer operations
253
- - Better user guidance with clear options for customer selection
337
+ ### Changed
338
+
339
+ - `newo status` now automatically checks all customers when no default is specified
340
+ - `newo push` provides interactive customer selection dialog when multiple customers exist
341
+ - Moved customer selection logic into command-specific handlers
342
+ - Each command now handles customer selection appropriately
254
343
 
255
344
  ### Fixed
256
- - **Command Flow**: Moved customer selection logic into command-specific handlers
257
- - Prevents early exit errors for multi-customer operations
258
- - Each command now handles customer selection appropriately
259
- - Maintains backward compatibility with single-customer setups
345
+
346
+ - Early exit errors for multi-customer operations
347
+ - Maintains backward compatibility with single-customer setups
260
348
 
261
349
  ## [1.7.0] - 2025-09-15
262
350
 
263
351
  ### Added
264
- - **Customer Attributes Synchronization**: Complete pull/push functionality for customer attributes
265
- - `GET /api/v1/bff/customer/attributes?include_hidden=true` - Fetches all 233 customer attributes including hidden system attributes
266
- - `PUT /api/v1/customer/attributes/{attributeId}` - Updates individual customer attributes
267
- - Saves to `newo_customers/{customerIdn}/attributes.yaml` in customer root directory
268
- - YAML format matches reference specification exactly with literal blocks, enum types, and proper multi-line formatting
269
- - Separate ID mapping stored in `.newo/{customerIdn}/attributes-map.json` for push operations
270
- - Integrated into existing `pull` and `push` commands seamlessly
271
- - Full TypeScript type safety with `CustomerAttribute` and `CustomerAttributesResponse` interfaces
272
352
 
273
- ### Enhanced
274
- - **YAML Format Compliance**: Perfect format matching with reference files
353
+ - Complete pull/push functionality for customer attributes
354
+ - `GET /api/v1/bff/customer/attributes?include_hidden=true` endpoint integration (fetches 233 attributes)
355
+ - `PUT /api/v1/customer/attributes/{attributeId}` endpoint integration
356
+ - Saves to `newo_customers/{customerIdn}/attributes.yaml` in customer root directory
357
+ - YAML format with literal blocks, enum types, and proper multi-line formatting
358
+ - Separate ID mapping in `.newo/{customerIdn}/attributes-map.json` for push operations
359
+ - Full TypeScript type safety with `CustomerAttribute` and `CustomerAttributesResponse` interfaces
360
+ - API layer functions: `updateCustomerAttribute()` and enhanced `getCustomerAttributes()`
361
+ - File system utilities: `customerAttributesPath()` and `customerAttributesMapPath()`
362
+
363
+ ### Changed
364
+
365
+ - Integrated attributes handling into existing `pull` and `push` commands
366
+ - YAML format compliance with reference specification
275
367
  - Literal block scalars (`|-`) for multi-line strings
276
368
  - Proper enum format (`!enum "AttributeValueTypes.string"`)
277
369
  - Complex JSON string formatting with proper line breaks
278
- - No escaped quotes in output for better readability
279
- - **Metadata Generation**: Removed legacy JSON metadata files, YAML-only approach
280
- - Eliminates redundant `metadata.json` files
281
- - Cleaner file structure with single source of truth
282
- - Improved performance with fewer file operations
283
-
284
- ### Technical
285
- - **API Layer**: Added `updateCustomerAttribute()` and enhanced `getCustomerAttributes()` with `includeHidden` parameter
286
- - **Sync Engine**: Integrated attributes handling into `pullAll()` and `pushChanged()` functions
287
- - **File System**: Added `customerAttributesPath()` and `customerAttributesMapPath()` utilities
288
- - **Type Safety**: Extended type definitions with proper customer attribute interfaces
289
- - **Error Handling**: Comprehensive error handling for attributes operations with graceful fallbacks
370
+ - No escaped quotes in output
371
+
372
+ ### Removed
373
+
374
+ - Legacy JSON metadata files (YAML-only approach)
375
+ - Redundant `metadata.json` files
290
376
 
291
377
  ## [1.6.1] - 2025-09-13
292
378
 
379
+ ### Added
380
+
381
+ - `"type": "module"` to package.json for proper ES module handling
382
+
293
383
  ### Fixed
294
- - **YAML Enum Formatting**: Fixed enum formatting in `flows.yaml` generation to properly handle NEWO enum types
295
- - Corrected enum value serialization from quoted strings to proper YAML enum format
296
- - Fixed issue where enum values like `!enum "RunnerType.guidance"` were incorrectly quoted
297
- - Ensures generated `flows.yaml` files are properly formatted for NEWO platform consumption
298
384
 
299
- ### Enhanced
300
- - **ES Module Support**: Added `"type": "module"` to package.json for proper ES module handling
301
- - Resolves Node.js warnings about module type detection
302
- - Improves performance by eliminating module type guessing
303
- - Ensures consistent ES module behavior across all environments
385
+ - Enum formatting in `flows.yaml` generation for NEWO enum types
386
+ - Enum value serialization from quoted strings to proper YAML enum format
387
+ - Issue where enum values like `!enum "RunnerType.guidance"` were incorrectly quoted
304
388
 
305
389
  ## [1.6.0] - 2025-09-13
306
390
 
@@ -352,7 +436,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
352
436
  - **Professional Infrastructure**: Industry-standard publishing pipeline with version management
353
437
  - **Quality Gates**: Automated validation before publishing (TypeScript, linting, building, package validation)
354
438
 
355
- ## [1.5.2] - 2025-01-15
439
+ ## [1.5.2] - 2025-09-04
356
440
 
357
441
  ### Enhanced
358
442
  - **Documentation Overhaul**: Complete README restructuring with professional presentation
@@ -382,7 +466,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
382
466
  - **Clear Navigation**: Improved documentation structure with proper sectioning and examples
383
467
  - **Enhanced Onboarding**: Comprehensive quick-start guide and configuration examples
384
468
 
385
- ## [1.5.1] - 2025-01-14
469
+ ## [1.5.1] - 2025-09-03
386
470
 
387
471
  ### Added
388
472
  - **Comprehensive Test Coverage**: Added extensive test suites for all major modules
@@ -605,10 +689,40 @@ Another Item: $Price [Modifiers: modifier3]
605
689
  ## [1.2.1] - Previous Release
606
690
 
607
691
  ### Added
692
+
608
693
  - Initial NEWO CLI functionality
609
694
  - Two-way sync between NEWO platform and local files
610
695
  - Support for .guidance and .jinja file types
611
696
  - SHA256-based change detection
612
697
  - Project structure export to flows.yaml
613
698
  - GitHub Actions CI/CD integration
614
- - Robust authentication with token refresh
699
+ - Robust authentication with token refresh
700
+
701
+ [Unreleased]: https://github.com/sabbah13/newo-cli/compare/v3.1.0...HEAD
702
+ [3.1.0]: https://github.com/sabbah13/newo-cli/compare/v3.0.0...v3.1.0
703
+ [3.0.0]: https://github.com/sabbah13/newo-cli/compare/v2.0.6...v3.0.0
704
+ [2.0.6]: https://github.com/sabbah13/newo-cli/compare/v2.0.5...v2.0.6
705
+ [2.0.5]: https://github.com/sabbah13/newo-cli/compare/v2.0.4...v2.0.5
706
+ [2.0.4]: https://github.com/sabbah13/newo-cli/compare/v2.0.3...v2.0.4
707
+ [2.0.3]: https://github.com/sabbah13/newo-cli/compare/v2.0.2...v2.0.3
708
+ [2.0.2]: https://github.com/sabbah13/newo-cli/compare/v2.0.1...v2.0.2
709
+ [2.0.1]: https://github.com/sabbah13/newo-cli/compare/v2.0.0...v2.0.1
710
+ [2.0.0]: https://github.com/sabbah13/newo-cli/compare/v1.8.0...v2.0.0
711
+ [1.9.3]: https://github.com/sabbah13/newo-cli/compare/v1.9.2...v1.9.3
712
+ [1.9.2]: https://github.com/sabbah13/newo-cli/compare/v1.9.1...v1.9.2
713
+ [1.9.1]: https://github.com/sabbah13/newo-cli/compare/v1.9.0...v1.9.1
714
+ [1.9.0]: https://github.com/sabbah13/newo-cli/compare/v1.8.0...v1.9.0
715
+ [1.8.0]: https://github.com/sabbah13/newo-cli/compare/v1.7.0...v1.8.0
716
+ [1.7.3]: https://github.com/sabbah13/newo-cli/compare/v1.7.2...v1.7.3
717
+ [1.7.2]: https://github.com/sabbah13/newo-cli/compare/v1.7.1...v1.7.2
718
+ [1.7.1]: https://github.com/sabbah13/newo-cli/compare/v1.7.0...v1.7.1
719
+ [1.7.0]: https://github.com/sabbah13/newo-cli/compare/v1.6.1...v1.7.0
720
+ [1.6.1]: https://github.com/sabbah13/newo-cli/compare/v1.6.0...v1.6.1
721
+ [1.6.0]: https://github.com/sabbah13/newo-cli/compare/v1.5.1...v1.6.0
722
+ [1.5.2]: https://github.com/sabbah13/newo-cli/compare/v1.5.1...v1.5.2
723
+ [1.5.1]: https://github.com/sabbah13/newo-cli/compare/v1.5.0...v1.5.1
724
+ [1.5.0]: https://github.com/sabbah13/newo-cli/compare/v1.4.0...v1.5.0
725
+ [1.4.0]: https://github.com/sabbah13/newo-cli/compare/v1.2.1...v1.4.0
726
+ [1.3.0]: https://github.com/sabbah13/newo-cli/compare/v1.2.1...v1.3.0
727
+ [1.2.2]: https://github.com/sabbah13/newo-cli/compare/v1.2.1...v1.2.2
728
+ [1.2.1]: https://github.com/sabbah13/newo-cli/releases/tag/v1.2.1