@indexnetwork/protocol 6.12.1-rc.404.1 → 6.13.22-rc.405.1
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/CHANGELOG.md +240 -0
- package/IMPLEMENTATION.md +20 -0
- package/STABILITY.md +4 -0
- package/dist/agent/agent.tools.d.ts +11 -3
- package/dist/agent/agent.tools.js +11 -301
- package/dist/capabilities/communities.facade.d.ts +13 -0
- package/dist/capabilities/communities.facade.js +12 -0
- package/dist/capabilities/communities.tools.port.d.ts +5 -0
- package/dist/capabilities/communities.tools.port.js +1 -0
- package/dist/capabilities/contacts.facade.d.ts +9 -0
- package/dist/capabilities/contacts.facade.js +8 -0
- package/dist/capabilities/contacts.tools.port.d.ts +9 -0
- package/dist/capabilities/contacts.tools.port.js +1 -0
- package/dist/capabilities/integrations.facade.d.ts +8 -0
- package/dist/capabilities/integrations.facade.js +7 -0
- package/dist/capabilities/integrations.tools.port.d.ts +9 -0
- package/dist/capabilities/integrations.tools.port.js +1 -0
- package/dist/capabilities/interaction-composition.facade.d.ts +10 -0
- package/dist/capabilities/interaction-composition.facade.js +9 -0
- package/dist/capabilities/negotiation.discovery.facade.d.ts +9 -0
- package/dist/capabilities/negotiation.discovery.facade.js +7 -0
- package/dist/capabilities/negotiation.facade.d.ts +23 -0
- package/dist/capabilities/negotiation.facade.js +17 -0
- package/dist/capabilities/negotiation.memory.facade.d.ts +6 -0
- package/dist/capabilities/negotiation.memory.facade.js +5 -0
- package/dist/capabilities/negotiation.questions.facade.d.ts +6 -0
- package/dist/capabilities/negotiation.questions.facade.js +5 -0
- package/dist/capabilities/negotiation.state.facade.d.ts +5 -0
- package/dist/capabilities/negotiation.state.facade.js +1 -0
- package/dist/capabilities/negotiation.summary.facade.d.ts +5 -0
- package/dist/capabilities/negotiation.summary.facade.js +5 -0
- package/dist/capabilities/negotiation.tools.port.d.ts +5 -0
- package/dist/capabilities/negotiation.tools.port.js +1 -0
- package/dist/capabilities/opportunities.facade.d.ts +50 -0
- package/dist/capabilities/opportunities.facade.js +50 -0
- package/dist/capabilities/opportunities.safety.facade.d.ts +2 -0
- package/dist/capabilities/opportunities.safety.facade.js +2 -0
- package/dist/capabilities/opportunities.tools.port.d.ts +5 -0
- package/dist/capabilities/opportunities.tools.port.js +1 -0
- package/dist/capabilities/participant-agents.debug.facade.d.ts +2 -0
- package/dist/capabilities/participant-agents.debug.facade.js +1 -0
- package/dist/capabilities/participant-agents.facade.d.ts +35 -0
- package/dist/capabilities/participant-agents.facade.js +35 -0
- package/dist/capabilities/participant-agents.tools.facade.d.ts +8 -0
- package/dist/capabilities/participant-agents.tools.facade.js +8 -0
- package/dist/capabilities/participant-agents.tools.port.d.ts +9 -0
- package/dist/capabilities/participant-agents.tools.port.js +1 -0
- package/dist/capabilities/participant-context.facade.d.ts +13 -0
- package/dist/capabilities/participant-context.facade.js +14 -0
- package/dist/capabilities/participant-context.tools.port.d.ts +9 -0
- package/dist/capabilities/participant-context.tools.port.js +1 -0
- package/dist/capabilities/questions.enqueue.facade.d.ts +5 -0
- package/dist/capabilities/questions.enqueue.facade.js +1 -0
- package/dist/capabilities/questions.facade.d.ts +8 -0
- package/dist/capabilities/questions.facade.js +7 -0
- package/dist/capabilities/questions.runtime.facade.d.ts +5 -0
- package/dist/capabilities/questions.runtime.facade.js +5 -0
- package/dist/capabilities/questions.tools.port.d.ts +5 -0
- package/dist/capabilities/questions.tools.port.js +1 -0
- package/dist/capabilities/signals.facade.d.ts +16 -0
- package/dist/capabilities/signals.facade.js +14 -0
- package/dist/capabilities/signals.indexing.facade.d.ts +12 -0
- package/dist/capabilities/signals.indexing.facade.js +11 -0
- package/dist/capabilities/signals.tools.port.d.ts +5 -0
- package/dist/capabilities/signals.tools.port.js +1 -0
- package/dist/chat/chat-streaming.types.d.ts +0 -1
- package/dist/chat/chat-streaming.types.js +1 -2
- package/dist/chat/chat.agent.d.ts +0 -1
- package/dist/chat/chat.agent.js +0 -1
- package/dist/chat/chat.graph.d.ts +0 -1
- package/dist/chat/chat.graph.js +0 -1
- package/dist/chat/chat.interrupt.classifier.d.ts +0 -1
- package/dist/chat/chat.interrupt.classifier.js +0 -1
- package/dist/chat/chat.persona.d.ts +0 -1
- package/dist/chat/chat.persona.js +0 -1
- package/dist/chat/chat.prompt.d.ts +0 -1
- package/dist/chat/chat.prompt.js +0 -1
- package/dist/chat/chat.prompt.modules.d.ts +0 -1
- package/dist/chat/chat.prompt.modules.js +0 -1
- package/dist/chat/chat.question-dedup.d.ts +0 -1
- package/dist/chat/chat.question-dedup.js +0 -1
- package/dist/chat/chat.state.d.ts +0 -1
- package/dist/chat/chat.state.js +0 -1
- package/dist/chat/chat.streamer.d.ts +0 -1
- package/dist/chat/chat.streamer.js +0 -1
- package/dist/chat/chat.suggester.d.ts +0 -1
- package/dist/chat/chat.suggester.js +0 -1
- package/dist/chat/chat.summarizer.d.ts +0 -1
- package/dist/chat/chat.summarizer.js +0 -1
- package/dist/chat/chat.title.generator.d.ts +0 -1
- package/dist/chat/chat.title.generator.js +0 -1
- package/dist/chat/chat.tools.d.ts +0 -1
- package/dist/chat/chat.tools.js +0 -1
- package/dist/chat/chat.utils.d.ts +0 -1
- package/dist/chat/chat.utils.js +0 -1
- package/dist/chat/negotiator.persona.d.ts +0 -1
- package/dist/chat/negotiator.persona.js +0 -1
- package/dist/chat/negotiator.prompt.d.ts +1 -2
- package/dist/chat/negotiator.prompt.js +1 -2
- package/dist/chat/negotiator.tools.d.ts +0 -1
- package/dist/chat/negotiator.tools.js +0 -1
- package/dist/chat/onboarding.persona.d.ts +0 -1
- package/dist/chat/onboarding.persona.js +0 -1
- package/dist/chat/onboarding.prompt.d.ts +0 -1
- package/dist/chat/onboarding.prompt.js +0 -1
- package/dist/chat/reporter.action.contracts.d.ts +36 -0
- package/dist/chat/reporter.action.contracts.js +1 -0
- package/dist/chat/reporter.action.tools.d.ts +2 -37
- package/dist/chat/reporter.action.tools.js +0 -1
- package/dist/chat/reporter.persona.d.ts +0 -1
- package/dist/chat/reporter.persona.js +0 -1
- package/dist/chat/reporter.prompt.d.ts +0 -1
- package/dist/chat/reporter.prompt.js +0 -1
- package/dist/chat/signal.persona.d.ts +0 -1
- package/dist/chat/signal.persona.js +0 -1
- package/dist/chat/signal.prompt.d.ts +0 -1
- package/dist/chat/signal.prompt.js +0 -1
- package/dist/communities/application/index.d.ts +45 -0
- package/dist/communities/application/index.js +50 -0
- package/dist/communities/application/indexer.graph.d.ts +446 -0
- package/dist/communities/application/indexer.graph.js +420 -0
- package/dist/communities/application/indexer.state.d.ts +172 -0
- package/dist/communities/application/indexer.state.js +116 -0
- package/dist/communities/application/membership.graph.d.ts +270 -0
- package/dist/communities/application/membership.graph.js +229 -0
- package/dist/communities/application/network.graph.d.ts +648 -0
- package/dist/communities/application/network.graph.js +303 -0
- package/dist/communities/application/network.recommender.d.ts +44 -0
- package/dist/communities/application/network.recommender.js +113 -0
- package/dist/communities/application/network.tools.d.ts +35 -0
- package/dist/communities/application/network.tools.js +578 -0
- package/dist/communities/domain/index.d.ts +29 -0
- package/dist/communities/domain/index.js +31 -0
- package/dist/communities/domain/membership.state.d.ts +87 -0
- package/dist/communities/domain/membership.state.js +53 -0
- package/dist/communities/domain/network.state.d.ts +192 -0
- package/dist/communities/domain/network.state.js +66 -0
- package/dist/communities/index.d.ts +14 -0
- package/dist/communities/index.js +14 -0
- package/dist/communities/ports/index.d.ts +25 -0
- package/dist/communities/ports/index.js +27 -0
- package/dist/communities/public/index.d.ts +30 -0
- package/dist/communities/public/index.js +33 -0
- package/dist/contact/contact.inviter.d.ts +7 -44
- package/dist/contact/contact.inviter.js +6 -59
- package/dist/contact/contact.tools.d.ts +7 -5
- package/dist/contact/contact.tools.js +7 -177
- package/dist/contacts/application/contact.inviter.d.ts +49 -0
- package/dist/contacts/application/contact.inviter.js +64 -0
- package/dist/contacts/application/contact.tools.d.ts +20 -0
- package/dist/contacts/application/contact.tools.js +191 -0
- package/dist/contacts/application/index.d.ts +22 -0
- package/dist/contacts/application/index.js +21 -0
- package/dist/contacts/domain/contact.types.d.ts +51 -0
- package/dist/contacts/domain/contact.types.js +10 -0
- package/dist/contacts/domain/index.d.ts +18 -0
- package/dist/contacts/domain/index.js +1 -0
- package/dist/contacts/index.d.ts +24 -0
- package/dist/contacts/index.js +24 -0
- package/dist/contacts/ports/contact.repository.port.d.ts +28 -0
- package/dist/contacts/ports/contact.repository.port.js +14 -0
- package/dist/contacts/ports/contact.tools.port.d.ts +26 -0
- package/dist/contacts/ports/contact.tools.port.js +21 -0
- package/dist/contacts/ports/index.d.ts +22 -0
- package/dist/contacts/ports/index.js +21 -0
- package/dist/contacts/public/index.d.ts +36 -0
- package/dist/contacts/public/index.js +33 -0
- package/dist/context/context.generator.d.ts +0 -1
- package/dist/context/context.generator.js +0 -1
- package/dist/enrichment/enrichment.enricher.d.ts +0 -1
- package/dist/enrichment/enrichment.enricher.js +0 -1
- package/dist/enrichment/enrichment.generator.d.ts +0 -1
- package/dist/enrichment/enrichment.generator.js +0 -1
- package/dist/enrichment/enrichment.graph.d.ts +6 -7
- package/dist/enrichment/enrichment.graph.js +0 -1
- package/dist/enrichment/enrichment.state.d.ts +2 -3
- package/dist/enrichment/enrichment.state.js +0 -1
- package/dist/enrichment/enrichment.tools.d.ts +3 -3
- package/dist/enrichment/enrichment.tools.js +0 -1
- package/dist/index.d.ts +106 -91
- package/dist/index.js +79 -71
- package/dist/integration/integration.tools.d.ts +6 -10
- package/dist/integration/integration.tools.js +6 -82
- package/dist/integrations/application/index.d.ts +14 -0
- package/dist/integrations/application/index.js +14 -0
- package/dist/integrations/application/integration.tools.d.ts +27 -0
- package/dist/integrations/application/integration.tools.js +98 -0
- package/dist/integrations/domain/index.d.ts +18 -0
- package/dist/integrations/domain/index.js +1 -0
- package/dist/integrations/domain/integration.types.d.ts +53 -0
- package/dist/integrations/domain/integration.types.js +11 -0
- package/dist/integrations/index.d.ts +27 -0
- package/dist/integrations/index.js +27 -0
- package/dist/integrations/ports/index.d.ts +28 -0
- package/dist/integrations/ports/index.js +26 -0
- package/dist/integrations/ports/integration.adapter.port.d.ts +62 -0
- package/dist/integrations/ports/integration.adapter.port.js +15 -0
- package/dist/integrations/ports/integration.importer.port.d.ts +31 -0
- package/dist/integrations/ports/integration.importer.port.js +15 -0
- package/dist/integrations/ports/integration.tools.port.d.ts +28 -0
- package/dist/integrations/ports/integration.tools.port.js +21 -0
- package/dist/integrations/public/index.d.ts +37 -0
- package/dist/integrations/public/index.js +34 -0
- package/dist/intent/intent.clarifier.d.ts +3 -52
- package/dist/intent/intent.clarifier.js +2 -202
- package/dist/intent/intent.graph.d.ts +3 -551
- package/dist/intent/intent.graph.js +3 -937
- package/dist/intent/intent.indexer.d.ts +2 -83
- package/dist/intent/intent.indexer.js +2 -171
- package/dist/intent/intent.inferrer.d.ts +2 -95
- package/dist/intent/intent.inferrer.js +2 -234
- package/dist/intent/intent.reconciler.d.ts +2 -106
- package/dist/intent/intent.reconciler.js +2 -187
- package/dist/intent/intent.specificity.d.ts +2 -3
- package/dist/intent/intent.specificity.js +2 -3
- package/dist/intent/intent.state.d.ts +8 -229
- package/dist/intent/intent.state.js +8 -189
- package/dist/intent/intent.tools.d.ts +6 -24
- package/dist/intent/intent.tools.js +4 -788
- package/dist/intent/intent.verifier.d.ts +2 -116
- package/dist/intent/intent.verifier.js +2 -263
- package/dist/maintenance/maintenance.graph.d.ts +0 -1
- package/dist/maintenance/maintenance.graph.js +0 -1
- package/dist/maintenance/maintenance.state.d.ts +0 -1
- package/dist/maintenance/maintenance.state.js +0 -1
- package/dist/mcp/elicitation.builder.d.ts +0 -1
- package/dist/mcp/elicitation.builder.js +0 -1
- package/dist/mcp/elicitation.dispatcher.d.ts +0 -1
- package/dist/mcp/elicitation.dispatcher.js +0 -1
- package/dist/mcp/mcp.server.d.ts +0 -1
- package/dist/mcp/mcp.server.js +1 -2
- package/dist/negotiation/application/index.d.ts +48 -0
- package/dist/negotiation/application/index.js +49 -0
- package/dist/negotiation/application/insight.generator.d.ts +31 -0
- package/dist/negotiation/application/insight.generator.js +105 -0
- package/dist/negotiation/application/negotiation.agent.d.ts +110 -0
- package/dist/negotiation/application/negotiation.agent.js +244 -0
- package/dist/negotiation/application/negotiation.detail-reader.d.ts +94 -0
- package/dist/negotiation/application/negotiation.detail-reader.js +91 -0
- package/dist/negotiation/application/negotiation.graph.d.ts +664 -0
- package/dist/negotiation/application/negotiation.graph.js +1393 -0
- package/dist/negotiation/application/negotiation.reflect.d.ts +194 -0
- package/dist/negotiation/application/negotiation.reflect.js +145 -0
- package/dist/negotiation/application/negotiation.screen.d.ts +78 -0
- package/dist/negotiation/application/negotiation.screen.js +108 -0
- package/dist/negotiation/application/negotiation.summarizer.d.ts +25 -0
- package/dist/negotiation/application/negotiation.summarizer.js +101 -0
- package/dist/negotiation/application/negotiation.tools.d.ts +18 -0
- package/dist/negotiation/application/negotiation.tools.js +782 -0
- package/dist/negotiation/domain/index.d.ts +48 -0
- package/dist/negotiation/domain/index.js +50 -0
- package/dist/negotiation/domain/negotiation.consultation-policy.d.ts +39 -0
- package/dist/negotiation/domain/negotiation.consultation-policy.js +68 -0
- package/dist/negotiation/domain/negotiation.deadlock.contracts.d.ts +10 -0
- package/dist/negotiation/domain/negotiation.deadlock.contracts.js +1 -0
- package/dist/negotiation/domain/negotiation.deadlock.d.ts +81 -0
- package/dist/negotiation/domain/negotiation.deadlock.js +103 -0
- package/dist/negotiation/domain/negotiation.intent-snapshot-provenance.d.ts +21 -0
- package/dist/negotiation/domain/negotiation.intent-snapshot-provenance.js +28 -0
- package/dist/negotiation/domain/negotiation.lifecycle-narration.d.ts +18 -0
- package/dist/negotiation/domain/negotiation.lifecycle-narration.js +87 -0
- package/dist/negotiation/domain/negotiation.memory.d.ts +65 -0
- package/dist/negotiation/domain/negotiation.memory.js +83 -0
- package/dist/negotiation/domain/negotiation.protocol.d.ts +536 -0
- package/dist/negotiation/domain/negotiation.protocol.js +202 -0
- package/dist/negotiation/domain/negotiation.question-safety.d.ts +25 -0
- package/dist/negotiation/domain/negotiation.question-safety.js +55 -0
- package/dist/negotiation/domain/negotiation.screen.contracts.d.ts +88 -0
- package/dist/negotiation/domain/negotiation.screen.contracts.js +58 -0
- package/dist/negotiation/domain/negotiation.state.d.ts +497 -0
- package/dist/negotiation/domain/negotiation.state.js +288 -0
- package/dist/negotiation/domain/negotiation.task-lock-policy.d.ts +10 -0
- package/dist/negotiation/domain/negotiation.task-lock-policy.js +22 -0
- package/dist/negotiation/index.d.ts +49 -0
- package/dist/negotiation/index.js +49 -0
- package/dist/negotiation/insight.generator.d.ts +3 -30
- package/dist/negotiation/insight.generator.js +3 -104
- package/dist/negotiation/negotiation.agent.d.ts +3 -109
- package/dist/negotiation/negotiation.agent.js +3 -248
- package/dist/negotiation/negotiation.attribution.d.ts +0 -1
- package/dist/negotiation/negotiation.attribution.js +0 -1
- package/dist/negotiation/negotiation.consultation-policy.d.ts +3 -38
- package/dist/negotiation/negotiation.consultation-policy.js +3 -67
- package/dist/negotiation/negotiation.deadlock.contracts.d.ts +5 -0
- package/dist/negotiation/negotiation.deadlock.contracts.js +5 -0
- package/dist/negotiation/negotiation.deadlock.d.ts +3 -94
- package/dist/negotiation/negotiation.deadlock.js +3 -101
- package/dist/negotiation/negotiation.detail-reader.d.ts +5 -0
- package/dist/negotiation/negotiation.detail-reader.js +5 -0
- package/dist/negotiation/negotiation.graph.d.ts +3 -663
- package/dist/negotiation/negotiation.graph.js +3 -1459
- package/dist/negotiation/negotiation.intent-snapshot-provenance.d.ts +5 -0
- package/dist/negotiation/negotiation.intent-snapshot-provenance.js +5 -0
- package/dist/negotiation/negotiation.lifecycle-narration.d.ts +5 -0
- package/dist/negotiation/negotiation.lifecycle-narration.js +5 -0
- package/dist/negotiation/negotiation.memory.d.ts +5 -56
- package/dist/negotiation/negotiation.memory.js +5 -69
- package/dist/negotiation/negotiation.protocol.d.ts +3 -535
- package/dist/negotiation/negotiation.protocol.js +3 -201
- package/dist/negotiation/negotiation.question-safety.d.ts +3 -24
- package/dist/negotiation/negotiation.question-safety.js +3 -54
- package/dist/negotiation/negotiation.reflect.d.ts +4 -197
- package/dist/negotiation/negotiation.reflect.js +4 -151
- package/dist/negotiation/negotiation.screen.d.ts +6 -159
- package/dist/negotiation/negotiation.screen.js +6 -152
- package/dist/negotiation/negotiation.state.d.ts +3 -495
- package/dist/negotiation/negotiation.state.js +3 -284
- package/dist/negotiation/negotiation.summarizer.d.ts +3 -24
- package/dist/negotiation/negotiation.summarizer.js +3 -100
- package/dist/negotiation/negotiation.task-lock-policy.d.ts +5 -0
- package/dist/negotiation/negotiation.task-lock-policy.js +5 -0
- package/dist/negotiation/negotiation.tools.d.ts +3 -15
- package/dist/negotiation/negotiation.tools.js +3 -946
- package/dist/negotiation/ports/index.d.ts +18 -0
- package/dist/negotiation/ports/index.js +18 -0
- package/dist/negotiation/ports/negotiation.tools.port.d.ts +18 -0
- package/dist/negotiation/ports/negotiation.tools.port.js +1 -0
- package/dist/negotiation/public/index.d.ts +58 -0
- package/dist/negotiation/public/index.js +60 -0
- package/dist/network/indexer/indexer.graph.d.ts +3 -413
- package/dist/network/indexer/indexer.graph.js +3 -375
- package/dist/network/indexer/indexer.state.d.ts +3 -149
- package/dist/network/indexer/indexer.state.js +3 -98
- package/dist/network/membership/membership.graph.d.ts +3 -248
- package/dist/network/membership/membership.graph.js +3 -202
- package/dist/network/membership/membership.state.d.ts +3 -75
- package/dist/network/membership/membership.state.js +3 -41
- package/dist/network/network.graph.d.ts +3 -629
- package/dist/network/network.graph.js +3 -267
- package/dist/network/network.recommender.d.ts +3 -40
- package/dist/network/network.recommender.js +3 -109
- package/dist/network/network.state.d.ts +3 -180
- package/dist/network/network.state.js +3 -54
- package/dist/network/network.tools.d.ts +5 -3
- package/dist/network/network.tools.js +5 -566
- package/dist/opportunity/application/delivery-card.cache.d.ts +25 -0
- package/dist/opportunity/application/delivery-card.cache.js +43 -0
- package/dist/opportunity/application/index.d.ts +63 -0
- package/dist/opportunity/application/index.js +68 -0
- package/dist/opportunity/application/negotiation-context.loader.d.ts +59 -0
- package/dist/opportunity/application/negotiation-context.loader.js +88 -0
- package/dist/opportunity/application/opportunity.card-presentation.d.ts +44 -0
- package/dist/opportunity/application/opportunity.card-presentation.js +104 -0
- package/dist/opportunity/application/opportunity.discover.d.ts +215 -0
- package/dist/opportunity/application/opportunity.discover.js +793 -0
- package/dist/opportunity/application/opportunity.discovery-continuation-finalization.d.ts +34 -0
- package/dist/opportunity/application/opportunity.discovery-continuation-finalization.js +74 -0
- package/dist/opportunity/application/opportunity.discovery-mcp-lifecycle-finalization.d.ts +44 -0
- package/dist/opportunity/application/opportunity.discovery-mcp-lifecycle-finalization.js +92 -0
- package/dist/opportunity/application/opportunity.discovery-negotiation-summary.d.ts +14 -0
- package/dist/opportunity/application/opportunity.discovery-negotiation-summary.js +46 -0
- package/dist/opportunity/application/opportunity.enricher.d.ts +71 -0
- package/dist/opportunity/application/opportunity.enricher.js +280 -0
- package/dist/opportunity/application/opportunity.evaluator.d.ts +275 -0
- package/dist/opportunity/application/opportunity.evaluator.js +459 -0
- package/dist/opportunity/application/opportunity.existing-negotiation.d.ts +77 -0
- package/dist/opportunity/application/opportunity.existing-negotiation.js +109 -0
- package/dist/opportunity/application/opportunity.feed-selection.d.ts +30 -0
- package/dist/opportunity/application/opportunity.feed-selection.js +96 -0
- package/dist/opportunity/application/opportunity.graph.d.ts +1427 -0
- package/dist/opportunity/application/opportunity.graph.js +3693 -0
- package/dist/opportunity/application/opportunity.introducer.d.ts +77 -0
- package/dist/opportunity/application/opportunity.introducer.js +99 -0
- package/dist/opportunity/application/opportunity.lifecycle.d.ts +63 -0
- package/dist/opportunity/application/opportunity.lifecycle.js +181 -0
- package/dist/opportunity/application/opportunity.newborn-stamping.d.ts +41 -0
- package/dist/opportunity/application/opportunity.newborn-stamping.js +81 -0
- package/dist/opportunity/application/opportunity.pending-questions.d.ts +33 -0
- package/dist/opportunity/application/opportunity.pending-questions.js +42 -0
- package/dist/opportunity/application/opportunity.persist.d.ts +58 -0
- package/dist/opportunity/application/opportunity.persist.js +145 -0
- package/dist/opportunity/application/opportunity.persistence-admission.d.ts +39 -0
- package/dist/opportunity/application/opportunity.persistence-admission.js +59 -0
- package/dist/opportunity/application/opportunity.presenter.d.ts +156 -0
- package/dist/opportunity/application/opportunity.presenter.js +736 -0
- package/dist/opportunity/application/opportunity.tools.d.ts +131 -0
- package/dist/opportunity/application/opportunity.tools.js +1834 -0
- package/dist/opportunity/application/opportunity.update-admission.d.ts +24 -0
- package/dist/opportunity/application/opportunity.update-admission.js +38 -0
- package/dist/opportunity/delivery-card.cache.d.ts +5 -26
- package/dist/opportunity/delivery-card.cache.js +5 -44
- package/dist/opportunity/discovery-question.helper.d.ts +3 -17
- package/dist/opportunity/discovery-question.helper.js +3 -14
- package/dist/opportunity/discriminator/discriminator.adjustments.d.ts +0 -1
- package/dist/opportunity/discriminator/discriminator.adjustments.js +0 -1
- package/dist/opportunity/discriminator/discriminator.assigner.d.ts +4 -5
- package/dist/opportunity/discriminator/discriminator.assigner.js +0 -1
- package/dist/opportunity/discriminator/discriminator.env.d.ts +0 -1
- package/dist/opportunity/discriminator/discriminator.env.js +0 -1
- package/dist/opportunity/discriminator/discriminator.miner.d.ts +0 -1
- package/dist/opportunity/discriminator/discriminator.miner.js +0 -1
- package/dist/opportunity/discriminator/discriminator.push.d.ts +0 -1
- package/dist/opportunity/discriminator/discriminator.push.js +0 -1
- package/dist/opportunity/discriminator/discriminator.question.d.ts +0 -1
- package/dist/opportunity/discriminator/discriminator.question.js +0 -1
- package/dist/opportunity/discriminator/discriminator.scorer.d.ts +0 -1
- package/dist/opportunity/discriminator/discriminator.scorer.js +0 -1
- package/dist/opportunity/discriminator/discriminator.shadow.d.ts +0 -1
- package/dist/opportunity/discriminator/discriminator.shadow.js +0 -1
- package/dist/opportunity/discriminator/discriminator.types.d.ts +0 -1
- package/dist/opportunity/discriminator/discriminator.types.js +0 -1
- package/dist/opportunity/domain/discovery-question.helper.d.ts +18 -0
- package/dist/opportunity/domain/discovery-question.helper.js +15 -0
- package/dist/opportunity/domain/index.d.ts +55 -0
- package/dist/opportunity/domain/index.js +52 -0
- package/dist/opportunity/domain/negotiation-summary.builder.d.ts +37 -0
- package/dist/opportunity/domain/negotiation-summary.builder.js +66 -0
- package/dist/opportunity/domain/opportunity.actor.d.ts +15 -0
- package/dist/opportunity/domain/opportunity.actor.js +39 -0
- package/dist/opportunity/domain/opportunity.claim-safety.d.ts +24 -0
- package/dist/opportunity/domain/opportunity.claim-safety.js +88 -0
- package/dist/opportunity/domain/opportunity.discovery-run-coalescing.d.ts +33 -0
- package/dist/opportunity/domain/opportunity.discovery-run-coalescing.js +33 -0
- package/dist/opportunity/domain/opportunity.discovery.contracts.d.ts +45 -0
- package/dist/opportunity/domain/opportunity.discovery.contracts.js +1 -0
- package/dist/opportunity/domain/opportunity.evidence.d.ts +21 -0
- package/dist/opportunity/domain/opportunity.evidence.js +78 -0
- package/dist/opportunity/domain/opportunity.labels.d.ts +8 -0
- package/dist/opportunity/domain/opportunity.labels.js +10 -0
- package/dist/opportunity/domain/opportunity.presentation-cache.d.ts +6 -0
- package/dist/opportunity/domain/opportunity.presentation-cache.js +14 -0
- package/dist/opportunity/domain/opportunity.presentation.d.ts +76 -0
- package/dist/opportunity/domain/opportunity.presentation.js +516 -0
- package/dist/opportunity/domain/opportunity.safe-presentation.d.ts +104 -0
- package/dist/opportunity/domain/opportunity.safe-presentation.js +102 -0
- package/dist/opportunity/domain/opportunity.state.d.ts +519 -0
- package/dist/opportunity/domain/opportunity.state.js +309 -0
- package/dist/opportunity/domain/opportunity.utils.d.ts +217 -0
- package/dist/opportunity/domain/opportunity.utils.js +395 -0
- package/dist/opportunity/feed/feed.categorizer.d.ts +0 -1
- package/dist/opportunity/feed/feed.categorizer.js +0 -1
- package/dist/opportunity/feed/feed.graph.d.ts +1 -2
- package/dist/opportunity/feed/feed.graph.js +0 -1
- package/dist/opportunity/feed/feed.health.d.ts +0 -1
- package/dist/opportunity/feed/feed.health.js +0 -1
- package/dist/opportunity/feed/feed.state.d.ts +1 -2
- package/dist/opportunity/feed/feed.state.js +0 -1
- package/dist/opportunity/index.d.ts +37 -0
- package/dist/opportunity/index.js +37 -0
- package/dist/opportunity/negotiation-context.loader.d.ts +3 -58
- package/dist/opportunity/negotiation-context.loader.js +3 -87
- package/dist/opportunity/negotiation-evidence/negotiation-evidence.env.d.ts +0 -1
- package/dist/opportunity/negotiation-evidence/negotiation-evidence.env.js +0 -1
- package/dist/opportunity/negotiation-evidence/negotiation-evidence.extractor.d.ts +0 -1
- package/dist/opportunity/negotiation-evidence/negotiation-evidence.extractor.js +0 -1
- package/dist/opportunity/negotiation-evidence/negotiation-evidence.miner.d.ts +0 -1
- package/dist/opportunity/negotiation-evidence/negotiation-evidence.miner.js +0 -1
- package/dist/opportunity/negotiation-evidence/negotiation-evidence.shadow.d.ts +0 -1
- package/dist/opportunity/negotiation-evidence/negotiation-evidence.shadow.js +0 -1
- package/dist/opportunity/negotiation-evidence/negotiation-evidence.types.d.ts +0 -1
- package/dist/opportunity/negotiation-evidence/negotiation-evidence.types.js +0 -1
- package/dist/opportunity/negotiation-evidence/negotiation-evidence.verifier.d.ts +0 -1
- package/dist/opportunity/negotiation-evidence/negotiation-evidence.verifier.js +0 -1
- package/dist/opportunity/negotiation-summary.builder.d.ts +3 -36
- package/dist/opportunity/negotiation-summary.builder.js +3 -65
- package/dist/opportunity/opportunity.actor.d.ts +3 -14
- package/dist/opportunity/opportunity.actor.js +3 -38
- package/dist/opportunity/opportunity.card-presentation.d.ts +5 -0
- package/dist/opportunity/opportunity.card-presentation.js +5 -0
- package/dist/opportunity/opportunity.claim-safety.d.ts +3 -23
- package/dist/opportunity/opportunity.claim-safety.js +3 -87
- package/dist/opportunity/opportunity.discover.d.ts +3 -218
- package/dist/opportunity/opportunity.discover.js +3 -917
- package/dist/opportunity/opportunity.discovery-continuation-finalization.d.ts +5 -0
- package/dist/opportunity/opportunity.discovery-continuation-finalization.js +5 -0
- package/dist/opportunity/opportunity.discovery-mcp-lifecycle-finalization.d.ts +5 -0
- package/dist/opportunity/opportunity.discovery-mcp-lifecycle-finalization.js +5 -0
- package/dist/opportunity/opportunity.discovery-negotiation-summary.d.ts +5 -0
- package/dist/opportunity/opportunity.discovery-negotiation-summary.js +5 -0
- package/dist/opportunity/opportunity.discovery-run-coalescing.d.ts +5 -0
- package/dist/opportunity/opportunity.discovery-run-coalescing.js +5 -0
- package/dist/opportunity/opportunity.discovery.contracts.d.ts +5 -0
- package/dist/opportunity/opportunity.discovery.contracts.js +5 -0
- package/dist/opportunity/opportunity.enricher.d.ts +3 -70
- package/dist/opportunity/opportunity.enricher.js +3 -279
- package/dist/opportunity/opportunity.evaluator.d.ts +5 -276
- package/dist/opportunity/opportunity.evaluator.js +5 -460
- package/dist/opportunity/opportunity.evidence.d.ts +5 -22
- package/dist/opportunity/opportunity.evidence.js +5 -79
- package/dist/opportunity/opportunity.existing-negotiation.d.ts +5 -0
- package/dist/opportunity/opportunity.existing-negotiation.js +5 -0
- package/dist/opportunity/opportunity.feed-selection.d.ts +5 -0
- package/dist/opportunity/opportunity.feed-selection.js +5 -0
- package/dist/opportunity/opportunity.graph.d.ts +3 -1489
- package/dist/opportunity/opportunity.graph.js +3 -4071
- package/dist/opportunity/opportunity.introducer.d.ts +3 -76
- package/dist/opportunity/opportunity.introducer.js +3 -98
- package/dist/opportunity/opportunity.labels.d.ts +5 -9
- package/dist/opportunity/opportunity.labels.js +5 -11
- package/dist/opportunity/opportunity.lifecycle.d.ts +5 -0
- package/dist/opportunity/opportunity.lifecycle.js +5 -0
- package/dist/opportunity/opportunity.newborn-stamping.d.ts +5 -0
- package/dist/opportunity/opportunity.newborn-stamping.js +5 -0
- package/dist/opportunity/opportunity.pending-questions.d.ts +3 -32
- package/dist/opportunity/opportunity.pending-questions.js +3 -41
- package/dist/opportunity/opportunity.persist.d.ts +3 -57
- package/dist/opportunity/opportunity.persist.js +3 -144
- package/dist/opportunity/opportunity.persistence-admission.d.ts +5 -0
- package/dist/opportunity/opportunity.persistence-admission.js +5 -0
- package/dist/opportunity/opportunity.presentation-cache.d.ts +5 -7
- package/dist/opportunity/opportunity.presentation-cache.js +5 -15
- package/dist/opportunity/opportunity.presentation.d.ts +3 -75
- package/dist/opportunity/opportunity.presentation.js +3 -515
- package/dist/opportunity/opportunity.presenter.d.ts +10 -155
- package/dist/opportunity/opportunity.presenter.js +10 -735
- package/dist/opportunity/opportunity.safe-presentation.d.ts +3 -103
- package/dist/opportunity/opportunity.safe-presentation.js +3 -101
- package/dist/opportunity/opportunity.state.d.ts +3 -518
- package/dist/opportunity/opportunity.state.js +3 -308
- package/dist/opportunity/opportunity.tools.d.ts +3 -157
- package/dist/opportunity/opportunity.tools.js +3 -2238
- package/dist/opportunity/opportunity.update-admission.d.ts +5 -0
- package/dist/opportunity/opportunity.update-admission.js +5 -0
- package/dist/opportunity/opportunity.utils.d.ts +3 -216
- package/dist/opportunity/opportunity.utils.js +3 -394
- package/dist/opportunity/outcome/outcome.env.d.ts +0 -1
- package/dist/opportunity/outcome/outcome.env.js +0 -1
- package/dist/opportunity/outcome/outcome.hypotheses.d.ts +0 -1
- package/dist/opportunity/outcome/outcome.hypotheses.js +0 -1
- package/dist/opportunity/outcome/outcome.shadow.d.ts +0 -1
- package/dist/opportunity/outcome/outcome.shadow.js +0 -1
- package/dist/opportunity/outcome/outcome.types.d.ts +0 -1
- package/dist/opportunity/outcome/outcome.types.js +0 -1
- package/dist/opportunity/ports/index.d.ts +5 -0
- package/dist/opportunity/ports/index.js +1 -0
- package/dist/opportunity/ports/opportunity.tools.port.d.ts +5 -0
- package/dist/opportunity/ports/opportunity.tools.port.js +1 -0
- package/dist/opportunity/public/index.d.ts +58 -0
- package/dist/opportunity/public/index.js +51 -0
- package/dist/participant-agents/application/agent.tools.d.ts +16 -0
- package/dist/participant-agents/application/agent.tools.js +313 -0
- package/dist/participant-agents/application/index.d.ts +21 -0
- package/dist/participant-agents/application/index.js +22 -0
- package/dist/participant-agents/domain/agent.types.d.ts +76 -0
- package/dist/participant-agents/domain/agent.types.js +22 -0
- package/dist/participant-agents/domain/index.d.ts +20 -0
- package/dist/participant-agents/domain/index.js +1 -0
- package/dist/participant-agents/index.d.ts +24 -0
- package/dist/participant-agents/index.js +24 -0
- package/dist/participant-agents/ports/agent.dispatcher.port.d.ts +25 -0
- package/dist/participant-agents/ports/agent.dispatcher.port.js +1 -0
- package/dist/participant-agents/ports/agent.repository.port.d.ts +118 -0
- package/dist/participant-agents/ports/agent.repository.port.js +10 -0
- package/dist/participant-agents/ports/agent.tools.port.d.ts +24 -0
- package/dist/participant-agents/ports/agent.tools.port.js +20 -0
- package/dist/participant-agents/ports/index.d.ts +29 -0
- package/dist/participant-agents/ports/index.js +27 -0
- package/dist/participant-agents/public/index.d.ts +39 -0
- package/dist/participant-agents/public/index.js +36 -0
- package/dist/participant-context/application/index.d.ts +73 -0
- package/dist/participant-context/application/index.js +83 -0
- package/dist/participant-context/domain/index.d.ts +67 -0
- package/dist/participant-context/domain/index.js +68 -0
- package/dist/participant-context/index.d.ts +16 -0
- package/dist/participant-context/index.js +16 -0
- package/dist/participant-context/ports/index.d.ts +37 -0
- package/dist/participant-context/ports/index.js +34 -0
- package/dist/participant-context/public/index.d.ts +48 -0
- package/dist/participant-context/public/index.js +55 -0
- package/dist/platform/index.d.ts +19 -0
- package/dist/platform/index.js +23 -0
- package/dist/premise/premise.analyzer.d.ts +0 -1
- package/dist/premise/premise.analyzer.js +0 -2
- package/dist/premise/premise.decomposer.d.ts +0 -1
- package/dist/premise/premise.decomposer.js +0 -2
- package/dist/premise/premise.graph.d.ts +1 -2
- package/dist/premise/premise.graph.js +0 -2
- package/dist/premise/premise.indexer.d.ts +0 -1
- package/dist/premise/premise.indexer.js +0 -2
- package/dist/premise/premise.state.d.ts +1 -2
- package/dist/premise/premise.state.js +0 -1
- package/dist/premise/premise.tools.d.ts +3 -3
- package/dist/premise/premise.tools.js +0 -2
- package/dist/public/index.d.ts +17 -0
- package/dist/public/index.js +17 -0
- package/dist/questioner/questioner.agent.d.ts +4 -27
- package/dist/questioner/questioner.agent.js +3 -133
- package/dist/questioner/questioner.ask.tool.d.ts +3 -12
- package/dist/questioner/questioner.ask.tool.js +3 -299
- package/dist/questioner/questioner.discovery.prompt.d.ts +3 -7
- package/dist/questioner/questioner.discovery.prompt.js +3 -180
- package/dist/questioner/questioner.env.d.ts +3 -57
- package/dist/questioner/questioner.env.js +3 -93
- package/dist/questioner/questioner.presets.d.ts +4 -19
- package/dist/questioner/questioner.presets.js +3 -465
- package/dist/questioner/questioner.qud.d.ts +3 -6
- package/dist/questioner/questioner.qud.js +3 -10
- package/dist/questioner/questioner.tools.d.ts +3 -15
- package/dist/questioner/questioner.tools.js +3 -186
- package/dist/questioner/questioner.types.d.ts +4 -218
- package/dist/questioner/questioner.types.js +5 -62
- package/dist/questions/application/index.d.ts +39 -0
- package/dist/questions/application/index.js +41 -0
- package/dist/questions/application/question.agent.d.ts +28 -0
- package/dist/questions/application/question.agent.js +139 -0
- package/dist/questions/application/question.ask.tool.d.ts +12 -0
- package/dist/questions/application/question.ask.tool.js +300 -0
- package/dist/questions/application/question.discovery.prompt.d.ts +8 -0
- package/dist/questions/application/question.discovery.prompt.js +181 -0
- package/dist/questions/application/question.env.d.ts +61 -0
- package/dist/questions/application/question.env.js +97 -0
- package/dist/questions/application/question.input.d.ts +237 -0
- package/dist/questions/application/question.input.js +61 -0
- package/dist/questions/application/question.presets.d.ts +24 -0
- package/dist/questions/application/question.presets.js +445 -0
- package/dist/questions/application/question.qud.d.ts +12 -0
- package/dist/questions/application/question.qud.js +16 -0
- package/dist/questions/application/question.tools.d.ts +15 -0
- package/dist/questions/application/question.tools.js +190 -0
- package/dist/questions/domain/index.d.ts +25 -0
- package/dist/questions/domain/index.js +25 -0
- package/dist/questions/domain/question.schema.d.ts +1537 -0
- package/dist/questions/domain/question.schema.js +422 -0
- package/dist/questions/index.d.ts +22 -0
- package/dist/questions/index.js +22 -0
- package/dist/questions/ports/index.d.ts +29 -0
- package/dist/questions/ports/index.js +27 -0
- package/dist/questions/ports/question.generator.port.d.ts +34 -0
- package/dist/questions/ports/question.generator.port.js +1 -0
- package/dist/questions/ports/question.persistence.port.d.ts +87 -0
- package/dist/questions/ports/question.persistence.port.js +1 -0
- package/dist/questions/ports/question.tools.port.d.ts +15 -0
- package/dist/questions/ports/question.tools.port.js +1 -0
- package/dist/questions/public/index.d.ts +47 -0
- package/dist/questions/public/index.js +49 -0
- package/dist/runtime/background/index.d.ts +14 -0
- package/dist/runtime/background/index.js +14 -0
- package/dist/runtime/foreground/composition/tool.factory.d.ts +16 -0
- package/dist/runtime/foreground/composition/tool.factory.js +224 -0
- package/dist/runtime/foreground/composition/tool.registry.d.ts +11 -0
- package/dist/runtime/foreground/composition/tool.registry.js +106 -0
- package/dist/runtime/foreground/index.d.ts +13 -0
- package/dist/runtime/foreground/index.js +13 -0
- package/dist/runtime/foreground/signals/intent.tools.d.ts +13 -0
- package/dist/runtime/foreground/signals/intent.tools.js +13 -0
- package/dist/shared/agent/model-signal.d.ts +0 -1
- package/dist/shared/agent/model-signal.js +0 -1
- package/dist/shared/agent/model.config.d.ts +0 -1
- package/dist/shared/agent/model.config.js +0 -1
- package/dist/shared/agent/tool.factory.d.ts +4 -15
- package/dist/shared/agent/tool.factory.js +4 -226
- package/dist/shared/agent/tool.helpers.d.ts +51 -12
- package/dist/shared/agent/tool.helpers.js +0 -1
- package/dist/shared/agent/tool.registry.d.ts +9 -9
- package/dist/shared/agent/tool.registry.js +9 -104
- package/dist/shared/agent/tool.runtime.d.ts +0 -1
- package/dist/shared/agent/tool.runtime.js +0 -1
- package/dist/shared/agent/tool.scope.d.ts +0 -1
- package/dist/shared/agent/tool.scope.js +0 -1
- package/dist/shared/agent/utility.tools.d.ts +5 -3
- package/dist/shared/agent/utility.tools.js +0 -1
- package/dist/shared/assignment/network-assignment.policy.d.ts +0 -1
- package/dist/shared/assignment/network-assignment.policy.js +0 -1
- package/dist/shared/hyde/hyde.documents.d.ts +0 -1
- package/dist/shared/hyde/hyde.documents.js +0 -1
- package/dist/shared/hyde/hyde.env.d.ts +0 -1
- package/dist/shared/hyde/hyde.env.js +0 -1
- package/dist/shared/hyde/hyde.frame.d.ts +4 -5
- package/dist/shared/hyde/hyde.frame.js +0 -1
- package/dist/shared/hyde/hyde.generator.d.ts +0 -1
- package/dist/shared/hyde/hyde.generator.js +0 -1
- package/dist/shared/hyde/hyde.graph.d.ts +0 -1
- package/dist/shared/hyde/hyde.graph.js +0 -1
- package/dist/shared/hyde/hyde.state.d.ts +0 -1
- package/dist/shared/hyde/hyde.state.js +0 -1
- package/dist/shared/hyde/hyde.strategies.d.ts +0 -1
- package/dist/shared/hyde/hyde.strategies.js +0 -1
- package/dist/shared/hyde/hyde.validator.d.ts +0 -1
- package/dist/shared/hyde/hyde.validator.js +0 -1
- package/dist/shared/hyde/lens.inferrer.d.ts +6 -7
- package/dist/shared/hyde/lens.inferrer.js +0 -1
- package/dist/shared/interfaces/agent-dispatcher.interface.d.ts +4 -1
- package/dist/shared/interfaces/agent-dispatcher.interface.js +4 -1
- package/dist/shared/interfaces/agent.interface.d.ts +13 -173
- package/dist/shared/interfaces/agent.interface.js +12 -12
- package/dist/shared/interfaces/auth.interface.d.ts +0 -1
- package/dist/shared/interfaces/auth.interface.js +0 -1
- package/dist/shared/interfaces/cache.interface.d.ts +0 -1
- package/dist/shared/interfaces/cache.interface.js +0 -1
- package/dist/shared/interfaces/chat-message-writer.interface.d.ts +0 -1
- package/dist/shared/interfaces/chat-message-writer.interface.js +0 -1
- package/dist/shared/interfaces/chat-session.interface.d.ts +0 -1
- package/dist/shared/interfaces/chat-session.interface.js +0 -1
- package/dist/shared/interfaces/chat-summary.interface.d.ts +0 -1
- package/dist/shared/interfaces/chat-summary.interface.js +0 -1
- package/dist/shared/interfaces/connect-link.interface.d.ts +0 -1
- package/dist/shared/interfaces/connect-link.interface.js +0 -1
- package/dist/shared/interfaces/contact.interface.d.ts +7 -55
- package/dist/shared/interfaces/contact.interface.js +7 -1
- package/dist/shared/interfaces/database.interface.d.ts +0 -1
- package/dist/shared/interfaces/database.interface.js +0 -1
- package/dist/shared/interfaces/delivery-ledger.interface.d.ts +0 -1
- package/dist/shared/interfaces/delivery-ledger.interface.js +0 -1
- package/dist/shared/interfaces/discovery-run.interface.d.ts +2 -3
- package/dist/shared/interfaces/discovery-run.interface.js +0 -1
- package/dist/shared/interfaces/embedder.interface.d.ts +0 -1
- package/dist/shared/interfaces/embedder.interface.js +0 -1
- package/dist/shared/interfaces/enrichment-run.interface.d.ts +2 -3
- package/dist/shared/interfaces/enrichment-run.interface.js +0 -1
- package/dist/shared/interfaces/enrichment.interface.d.ts +0 -1
- package/dist/shared/interfaces/enrichment.interface.js +0 -1
- package/dist/shared/interfaces/integration.interface.d.ts +6 -88
- package/dist/shared/interfaces/integration.interface.js +7 -1
- package/dist/shared/interfaces/negotiation-events.interface.d.ts +0 -1
- package/dist/shared/interfaces/negotiation-events.interface.js +0 -1
- package/dist/shared/interfaces/negotiation-summary.interface.d.ts +0 -1
- package/dist/shared/interfaces/negotiation-summary.interface.js +0 -1
- package/dist/shared/interfaces/negotiator-memory.interface.d.ts +0 -1
- package/dist/shared/interfaces/negotiator-memory.interface.js +0 -1
- package/dist/shared/interfaces/question-generator.interface.d.ts +3 -28
- package/dist/shared/interfaces/question-generator.interface.js +0 -1
- package/dist/shared/interfaces/questioner.interface.d.ts +3 -77
- package/dist/shared/interfaces/questioner.interface.js +0 -1
- package/dist/shared/interfaces/queue.interface.d.ts +0 -1
- package/dist/shared/interfaces/queue.interface.js +0 -1
- package/dist/shared/interfaces/scraper.interface.d.ts +0 -1
- package/dist/shared/interfaces/scraper.interface.js +0 -1
- package/dist/shared/interfaces/tool-request-context.interface.d.ts +12 -0
- package/dist/shared/interfaces/tool-request-context.interface.js +1 -0
- package/dist/shared/network/metadata.renderer.d.ts +0 -1
- package/dist/shared/network/metadata.renderer.js +0 -1
- package/dist/shared/observability/debug-meta.sanitizer.d.ts +0 -1
- package/dist/shared/observability/debug-meta.sanitizer.js +0 -1
- package/dist/shared/observability/log.d.ts +0 -1
- package/dist/shared/observability/log.js +0 -1
- package/dist/shared/observability/performance.d.ts +0 -1
- package/dist/shared/observability/performance.js +0 -1
- package/dist/shared/observability/protocol.logger.d.ts +0 -1
- package/dist/shared/observability/protocol.logger.js +0 -1
- package/dist/shared/observability/request-context.d.ts +0 -1
- package/dist/shared/observability/request-context.js +0 -1
- package/dist/shared/observability/trace.d.ts +0 -1
- package/dist/shared/observability/trace.js +0 -1
- package/dist/shared/schemas/chat-context.schema.d.ts +0 -1
- package/dist/shared/schemas/chat-context.schema.js +0 -1
- package/dist/shared/schemas/discovery-question.schema.d.ts +17 -18
- package/dist/shared/schemas/discovery-question.schema.js +0 -1
- package/dist/shared/schemas/identity.schema.d.ts +0 -1
- package/dist/shared/schemas/identity.schema.js +0 -1
- package/dist/shared/schemas/mcp-auth.schema.d.ts +0 -1
- package/dist/shared/schemas/mcp-auth.schema.js +0 -1
- package/dist/shared/schemas/negotiation-digest.schema.d.ts +5 -6
- package/dist/shared/schemas/negotiation-digest.schema.js +0 -1
- package/dist/shared/schemas/negotiation-state.schema.d.ts +4 -5
- package/dist/shared/schemas/negotiation-state.schema.js +0 -1
- package/dist/shared/schemas/network-assignment.schema.d.ts +0 -1
- package/dist/shared/schemas/network-assignment.schema.js +0 -1
- package/dist/shared/schemas/pending-question.schema.d.ts +0 -1
- package/dist/shared/schemas/pending-question.schema.js +0 -1
- package/dist/shared/schemas/question.schema.d.ts +3 -1535
- package/dist/shared/schemas/question.schema.js +3 -420
- package/dist/shared/ui/lucide.icon-catalog.d.ts +0 -1
- package/dist/shared/ui/lucide.icon-catalog.js +0 -1
- package/dist/shared/utils/social-label.d.ts +0 -1
- package/dist/shared/utils/social-label.js +0 -1
- package/dist/shared/utils/telegram-handle.d.ts +0 -1
- package/dist/shared/utils/telegram-handle.js +0 -1
- package/dist/signals/application/index.d.ts +19 -0
- package/dist/signals/application/index.js +22 -0
- package/dist/signals/application/intent.clarifier.d.ts +51 -0
- package/dist/signals/application/intent.clarifier.js +201 -0
- package/dist/signals/application/intent.graph.d.ts +552 -0
- package/dist/signals/application/intent.graph.js +938 -0
- package/dist/signals/application/intent.indexer.d.ts +82 -0
- package/dist/signals/application/intent.indexer.js +170 -0
- package/dist/signals/application/intent.inferrer.d.ts +94 -0
- package/dist/signals/application/intent.inferrer.js +233 -0
- package/dist/signals/application/intent.reconciler.d.ts +105 -0
- package/dist/signals/application/intent.reconciler.js +186 -0
- package/dist/signals/application/intent.tools.d.ts +24 -0
- package/dist/signals/application/intent.tools.js +789 -0
- package/dist/signals/application/intent.verifier.d.ts +115 -0
- package/dist/signals/application/intent.verifier.js +262 -0
- package/dist/signals/domain/index.d.ts +9 -0
- package/dist/signals/domain/index.js +11 -0
- package/dist/signals/domain/intent.state.d.ts +230 -0
- package/dist/signals/domain/intent.state.js +190 -0
- package/dist/signals/domain/signal.specificity.d.ts +2 -0
- package/dist/signals/domain/signal.specificity.js +2 -0
- package/dist/signals/index.d.ts +13 -0
- package/dist/signals/index.js +13 -0
- package/dist/signals/ports/index.d.ts +15 -0
- package/dist/signals/ports/index.js +13 -0
- package/dist/signals/public/index.d.ts +15 -0
- package/dist/signals/public/index.js +16 -0
- package/package.json +14 -3
- package/dist/agent/agent.tools.d.ts.map +0 -1
- package/dist/agent/agent.tools.js.map +0 -1
- package/dist/agent/tests/fakes.d.ts +0 -25
- package/dist/agent/tests/fakes.d.ts.map +0 -1
- package/dist/agent/tests/fakes.js +0 -178
- package/dist/agent/tests/fakes.js.map +0 -1
- package/dist/chat/chat-streaming.types.d.ts.map +0 -1
- package/dist/chat/chat-streaming.types.js.map +0 -1
- package/dist/chat/chat.agent.d.ts.map +0 -1
- package/dist/chat/chat.agent.js.map +0 -1
- package/dist/chat/chat.graph.d.ts.map +0 -1
- package/dist/chat/chat.graph.js.map +0 -1
- package/dist/chat/chat.interrupt.classifier.d.ts.map +0 -1
- package/dist/chat/chat.interrupt.classifier.js.map +0 -1
- package/dist/chat/chat.persona.d.ts.map +0 -1
- package/dist/chat/chat.persona.js.map +0 -1
- package/dist/chat/chat.prompt.d.ts.map +0 -1
- package/dist/chat/chat.prompt.js.map +0 -1
- package/dist/chat/chat.prompt.modules.d.ts.map +0 -1
- package/dist/chat/chat.prompt.modules.js.map +0 -1
- package/dist/chat/chat.question-dedup.d.ts.map +0 -1
- package/dist/chat/chat.question-dedup.js.map +0 -1
- package/dist/chat/chat.state.d.ts.map +0 -1
- package/dist/chat/chat.state.js.map +0 -1
- package/dist/chat/chat.streamer.d.ts.map +0 -1
- package/dist/chat/chat.streamer.js.map +0 -1
- package/dist/chat/chat.suggester.d.ts.map +0 -1
- package/dist/chat/chat.suggester.js.map +0 -1
- package/dist/chat/chat.summarizer.d.ts.map +0 -1
- package/dist/chat/chat.summarizer.js.map +0 -1
- package/dist/chat/chat.title.generator.d.ts.map +0 -1
- package/dist/chat/chat.title.generator.js.map +0 -1
- package/dist/chat/chat.tools.d.ts.map +0 -1
- package/dist/chat/chat.tools.js.map +0 -1
- package/dist/chat/chat.utils.d.ts.map +0 -1
- package/dist/chat/chat.utils.js.map +0 -1
- package/dist/chat/negotiator.persona.d.ts.map +0 -1
- package/dist/chat/negotiator.persona.js.map +0 -1
- package/dist/chat/negotiator.prompt.d.ts.map +0 -1
- package/dist/chat/negotiator.prompt.js.map +0 -1
- package/dist/chat/negotiator.tools.d.ts.map +0 -1
- package/dist/chat/negotiator.tools.js.map +0 -1
- package/dist/chat/onboarding.persona.d.ts.map +0 -1
- package/dist/chat/onboarding.persona.js.map +0 -1
- package/dist/chat/onboarding.prompt.d.ts.map +0 -1
- package/dist/chat/onboarding.prompt.js.map +0 -1
- package/dist/chat/reporter.action.tools.d.ts.map +0 -1
- package/dist/chat/reporter.action.tools.js.map +0 -1
- package/dist/chat/reporter.persona.d.ts.map +0 -1
- package/dist/chat/reporter.persona.js.map +0 -1
- package/dist/chat/reporter.prompt.d.ts.map +0 -1
- package/dist/chat/reporter.prompt.js.map +0 -1
- package/dist/chat/signal.persona.d.ts.map +0 -1
- package/dist/chat/signal.persona.js.map +0 -1
- package/dist/chat/signal.prompt.d.ts.map +0 -1
- package/dist/chat/signal.prompt.js.map +0 -1
- package/dist/chat/tests/chat.graph.mocks.d.ts +0 -98
- package/dist/chat/tests/chat.graph.mocks.d.ts.map +0 -1
- package/dist/chat/tests/chat.graph.mocks.js +0 -225
- package/dist/chat/tests/chat.graph.mocks.js.map +0 -1
- package/dist/contact/contact.inviter.d.ts.map +0 -1
- package/dist/contact/contact.inviter.js.map +0 -1
- package/dist/contact/contact.tools.d.ts.map +0 -1
- package/dist/contact/contact.tools.js.map +0 -1
- package/dist/context/context.generator.d.ts.map +0 -1
- package/dist/context/context.generator.js.map +0 -1
- package/dist/enrichment/enrichment.enricher.d.ts.map +0 -1
- package/dist/enrichment/enrichment.enricher.js.map +0 -1
- package/dist/enrichment/enrichment.generator.d.ts.map +0 -1
- package/dist/enrichment/enrichment.generator.js.map +0 -1
- package/dist/enrichment/enrichment.graph.d.ts.map +0 -1
- package/dist/enrichment/enrichment.graph.js.map +0 -1
- package/dist/enrichment/enrichment.state.d.ts.map +0 -1
- package/dist/enrichment/enrichment.state.js.map +0 -1
- package/dist/enrichment/enrichment.tools.d.ts.map +0 -1
- package/dist/enrichment/enrichment.tools.js.map +0 -1
- package/dist/index.d.ts.map +0 -1
- package/dist/index.js.map +0 -1
- package/dist/integration/integration.tools.d.ts.map +0 -1
- package/dist/integration/integration.tools.js.map +0 -1
- package/dist/intent/intent.clarifier.d.ts.map +0 -1
- package/dist/intent/intent.clarifier.js.map +0 -1
- package/dist/intent/intent.graph.d.ts.map +0 -1
- package/dist/intent/intent.graph.js.map +0 -1
- package/dist/intent/intent.indexer.d.ts.map +0 -1
- package/dist/intent/intent.indexer.js.map +0 -1
- package/dist/intent/intent.inferrer.d.ts.map +0 -1
- package/dist/intent/intent.inferrer.js.map +0 -1
- package/dist/intent/intent.reconciler.d.ts.map +0 -1
- package/dist/intent/intent.reconciler.js.map +0 -1
- package/dist/intent/intent.specificity.d.ts.map +0 -1
- package/dist/intent/intent.specificity.js.map +0 -1
- package/dist/intent/intent.state.d.ts.map +0 -1
- package/dist/intent/intent.state.js.map +0 -1
- package/dist/intent/intent.tools.d.ts.map +0 -1
- package/dist/intent/intent.tools.js.map +0 -1
- package/dist/intent/intent.verifier.d.ts.map +0 -1
- package/dist/intent/intent.verifier.js.map +0 -1
- package/dist/maintenance/maintenance.graph.d.ts.map +0 -1
- package/dist/maintenance/maintenance.graph.js.map +0 -1
- package/dist/maintenance/maintenance.state.d.ts.map +0 -1
- package/dist/maintenance/maintenance.state.js.map +0 -1
- package/dist/mcp/elicitation.builder.d.ts.map +0 -1
- package/dist/mcp/elicitation.builder.js.map +0 -1
- package/dist/mcp/elicitation.dispatcher.d.ts.map +0 -1
- package/dist/mcp/elicitation.dispatcher.js.map +0 -1
- package/dist/mcp/mcp.server.d.ts.map +0 -1
- package/dist/mcp/mcp.server.js.map +0 -1
- package/dist/negotiation/insight.generator.d.ts.map +0 -1
- package/dist/negotiation/insight.generator.js.map +0 -1
- package/dist/negotiation/negotiation.agent.d.ts.map +0 -1
- package/dist/negotiation/negotiation.agent.js.map +0 -1
- package/dist/negotiation/negotiation.attribution.d.ts.map +0 -1
- package/dist/negotiation/negotiation.attribution.js.map +0 -1
- package/dist/negotiation/negotiation.consultation-policy.d.ts.map +0 -1
- package/dist/negotiation/negotiation.consultation-policy.js.map +0 -1
- package/dist/negotiation/negotiation.deadlock.d.ts.map +0 -1
- package/dist/negotiation/negotiation.deadlock.js.map +0 -1
- package/dist/negotiation/negotiation.graph.d.ts.map +0 -1
- package/dist/negotiation/negotiation.graph.js.map +0 -1
- package/dist/negotiation/negotiation.memory.d.ts.map +0 -1
- package/dist/negotiation/negotiation.memory.js.map +0 -1
- package/dist/negotiation/negotiation.protocol.d.ts.map +0 -1
- package/dist/negotiation/negotiation.protocol.js.map +0 -1
- package/dist/negotiation/negotiation.question-safety.d.ts.map +0 -1
- package/dist/negotiation/negotiation.question-safety.js.map +0 -1
- package/dist/negotiation/negotiation.reflect.d.ts.map +0 -1
- package/dist/negotiation/negotiation.reflect.js.map +0 -1
- package/dist/negotiation/negotiation.screen.d.ts.map +0 -1
- package/dist/negotiation/negotiation.screen.js.map +0 -1
- package/dist/negotiation/negotiation.state.d.ts.map +0 -1
- package/dist/negotiation/negotiation.state.js.map +0 -1
- package/dist/negotiation/negotiation.summarizer.d.ts.map +0 -1
- package/dist/negotiation/negotiation.summarizer.js.map +0 -1
- package/dist/negotiation/negotiation.tools.d.ts.map +0 -1
- package/dist/negotiation/negotiation.tools.js.map +0 -1
- package/dist/network/indexer/indexer.graph.d.ts.map +0 -1
- package/dist/network/indexer/indexer.graph.js.map +0 -1
- package/dist/network/indexer/indexer.state.d.ts.map +0 -1
- package/dist/network/indexer/indexer.state.js.map +0 -1
- package/dist/network/membership/membership.graph.d.ts.map +0 -1
- package/dist/network/membership/membership.graph.js.map +0 -1
- package/dist/network/membership/membership.state.d.ts.map +0 -1
- package/dist/network/membership/membership.state.js.map +0 -1
- package/dist/network/network.graph.d.ts.map +0 -1
- package/dist/network/network.graph.js.map +0 -1
- package/dist/network/network.recommender.d.ts.map +0 -1
- package/dist/network/network.recommender.js.map +0 -1
- package/dist/network/network.state.d.ts.map +0 -1
- package/dist/network/network.state.js.map +0 -1
- package/dist/network/network.tools.d.ts.map +0 -1
- package/dist/network/network.tools.js.map +0 -1
- package/dist/opportunity/delivery-card.cache.d.ts.map +0 -1
- package/dist/opportunity/delivery-card.cache.js.map +0 -1
- package/dist/opportunity/discovery-question.helper.d.ts.map +0 -1
- package/dist/opportunity/discovery-question.helper.js.map +0 -1
- package/dist/opportunity/discriminator/discriminator.adjustments.d.ts.map +0 -1
- package/dist/opportunity/discriminator/discriminator.adjustments.js.map +0 -1
- package/dist/opportunity/discriminator/discriminator.assigner.d.ts.map +0 -1
- package/dist/opportunity/discriminator/discriminator.assigner.js.map +0 -1
- package/dist/opportunity/discriminator/discriminator.env.d.ts.map +0 -1
- package/dist/opportunity/discriminator/discriminator.env.js.map +0 -1
- package/dist/opportunity/discriminator/discriminator.miner.d.ts.map +0 -1
- package/dist/opportunity/discriminator/discriminator.miner.js.map +0 -1
- package/dist/opportunity/discriminator/discriminator.push.d.ts.map +0 -1
- package/dist/opportunity/discriminator/discriminator.push.js.map +0 -1
- package/dist/opportunity/discriminator/discriminator.question.d.ts.map +0 -1
- package/dist/opportunity/discriminator/discriminator.question.js.map +0 -1
- package/dist/opportunity/discriminator/discriminator.scorer.d.ts.map +0 -1
- package/dist/opportunity/discriminator/discriminator.scorer.js.map +0 -1
- package/dist/opportunity/discriminator/discriminator.shadow.d.ts.map +0 -1
- package/dist/opportunity/discriminator/discriminator.shadow.js.map +0 -1
- package/dist/opportunity/discriminator/discriminator.types.d.ts.map +0 -1
- package/dist/opportunity/discriminator/discriminator.types.js.map +0 -1
- package/dist/opportunity/feed/feed.categorizer.d.ts.map +0 -1
- package/dist/opportunity/feed/feed.categorizer.js.map +0 -1
- package/dist/opportunity/feed/feed.graph.d.ts.map +0 -1
- package/dist/opportunity/feed/feed.graph.js.map +0 -1
- package/dist/opportunity/feed/feed.health.d.ts.map +0 -1
- package/dist/opportunity/feed/feed.health.js.map +0 -1
- package/dist/opportunity/feed/feed.state.d.ts.map +0 -1
- package/dist/opportunity/feed/feed.state.js.map +0 -1
- package/dist/opportunity/negotiation-context.loader.d.ts.map +0 -1
- package/dist/opportunity/negotiation-context.loader.js.map +0 -1
- package/dist/opportunity/negotiation-evidence/negotiation-evidence.env.d.ts.map +0 -1
- package/dist/opportunity/negotiation-evidence/negotiation-evidence.env.js.map +0 -1
- package/dist/opportunity/negotiation-evidence/negotiation-evidence.extractor.d.ts.map +0 -1
- package/dist/opportunity/negotiation-evidence/negotiation-evidence.extractor.js.map +0 -1
- package/dist/opportunity/negotiation-evidence/negotiation-evidence.miner.d.ts.map +0 -1
- package/dist/opportunity/negotiation-evidence/negotiation-evidence.miner.js.map +0 -1
- package/dist/opportunity/negotiation-evidence/negotiation-evidence.shadow.d.ts.map +0 -1
- package/dist/opportunity/negotiation-evidence/negotiation-evidence.shadow.js.map +0 -1
- package/dist/opportunity/negotiation-evidence/negotiation-evidence.types.d.ts.map +0 -1
- package/dist/opportunity/negotiation-evidence/negotiation-evidence.types.js.map +0 -1
- package/dist/opportunity/negotiation-evidence/negotiation-evidence.verifier.d.ts.map +0 -1
- package/dist/opportunity/negotiation-evidence/negotiation-evidence.verifier.js.map +0 -1
- package/dist/opportunity/negotiation-summary.builder.d.ts.map +0 -1
- package/dist/opportunity/negotiation-summary.builder.js.map +0 -1
- package/dist/opportunity/opportunity.actor.d.ts.map +0 -1
- package/dist/opportunity/opportunity.actor.js.map +0 -1
- package/dist/opportunity/opportunity.claim-safety.d.ts.map +0 -1
- package/dist/opportunity/opportunity.claim-safety.js.map +0 -1
- package/dist/opportunity/opportunity.discover.d.ts.map +0 -1
- package/dist/opportunity/opportunity.discover.js.map +0 -1
- package/dist/opportunity/opportunity.enricher.d.ts.map +0 -1
- package/dist/opportunity/opportunity.enricher.js.map +0 -1
- package/dist/opportunity/opportunity.evaluator.d.ts.map +0 -1
- package/dist/opportunity/opportunity.evaluator.js.map +0 -1
- package/dist/opportunity/opportunity.evidence.d.ts.map +0 -1
- package/dist/opportunity/opportunity.evidence.js.map +0 -1
- package/dist/opportunity/opportunity.graph.d.ts.map +0 -1
- package/dist/opportunity/opportunity.graph.js.map +0 -1
- package/dist/opportunity/opportunity.introducer.d.ts.map +0 -1
- package/dist/opportunity/opportunity.introducer.js.map +0 -1
- package/dist/opportunity/opportunity.labels.d.ts.map +0 -1
- package/dist/opportunity/opportunity.labels.js.map +0 -1
- package/dist/opportunity/opportunity.pending-questions.d.ts.map +0 -1
- package/dist/opportunity/opportunity.pending-questions.js.map +0 -1
- package/dist/opportunity/opportunity.persist.d.ts.map +0 -1
- package/dist/opportunity/opportunity.persist.js.map +0 -1
- package/dist/opportunity/opportunity.presentation-cache.d.ts.map +0 -1
- package/dist/opportunity/opportunity.presentation-cache.js.map +0 -1
- package/dist/opportunity/opportunity.presentation.d.ts.map +0 -1
- package/dist/opportunity/opportunity.presentation.js.map +0 -1
- package/dist/opportunity/opportunity.presenter.d.ts.map +0 -1
- package/dist/opportunity/opportunity.presenter.js.map +0 -1
- package/dist/opportunity/opportunity.safe-presentation.d.ts.map +0 -1
- package/dist/opportunity/opportunity.safe-presentation.js.map +0 -1
- package/dist/opportunity/opportunity.state.d.ts.map +0 -1
- package/dist/opportunity/opportunity.state.js.map +0 -1
- package/dist/opportunity/opportunity.tools.d.ts.map +0 -1
- package/dist/opportunity/opportunity.tools.js.map +0 -1
- package/dist/opportunity/opportunity.utils.d.ts.map +0 -1
- package/dist/opportunity/opportunity.utils.js.map +0 -1
- package/dist/opportunity/outcome/outcome.env.d.ts.map +0 -1
- package/dist/opportunity/outcome/outcome.env.js.map +0 -1
- package/dist/opportunity/outcome/outcome.hypotheses.d.ts.map +0 -1
- package/dist/opportunity/outcome/outcome.hypotheses.js.map +0 -1
- package/dist/opportunity/outcome/outcome.shadow.d.ts.map +0 -1
- package/dist/opportunity/outcome/outcome.shadow.js.map +0 -1
- package/dist/opportunity/outcome/outcome.types.d.ts.map +0 -1
- package/dist/opportunity/outcome/outcome.types.js.map +0 -1
- package/dist/premise/premise.analyzer.d.ts.map +0 -1
- package/dist/premise/premise.analyzer.js.map +0 -1
- package/dist/premise/premise.decomposer.d.ts.map +0 -1
- package/dist/premise/premise.decomposer.js.map +0 -1
- package/dist/premise/premise.graph.d.ts.map +0 -1
- package/dist/premise/premise.graph.js.map +0 -1
- package/dist/premise/premise.indexer.d.ts.map +0 -1
- package/dist/premise/premise.indexer.js.map +0 -1
- package/dist/premise/premise.state.d.ts.map +0 -1
- package/dist/premise/premise.state.js.map +0 -1
- package/dist/premise/premise.tools.d.ts.map +0 -1
- package/dist/premise/premise.tools.js.map +0 -1
- package/dist/questioner/questioner.agent.d.ts.map +0 -1
- package/dist/questioner/questioner.agent.js.map +0 -1
- package/dist/questioner/questioner.ask.tool.d.ts.map +0 -1
- package/dist/questioner/questioner.ask.tool.js.map +0 -1
- package/dist/questioner/questioner.discovery.prompt.d.ts.map +0 -1
- package/dist/questioner/questioner.discovery.prompt.js.map +0 -1
- package/dist/questioner/questioner.env.d.ts.map +0 -1
- package/dist/questioner/questioner.env.js.map +0 -1
- package/dist/questioner/questioner.presets.d.ts.map +0 -1
- package/dist/questioner/questioner.presets.js.map +0 -1
- package/dist/questioner/questioner.qud.d.ts.map +0 -1
- package/dist/questioner/questioner.qud.js.map +0 -1
- package/dist/questioner/questioner.tools.d.ts.map +0 -1
- package/dist/questioner/questioner.tools.js.map +0 -1
- package/dist/questioner/questioner.types.d.ts.map +0 -1
- package/dist/questioner/questioner.types.js.map +0 -1
- package/dist/shared/agent/model-signal.d.ts.map +0 -1
- package/dist/shared/agent/model-signal.js.map +0 -1
- package/dist/shared/agent/model.config.d.ts.map +0 -1
- package/dist/shared/agent/model.config.js.map +0 -1
- package/dist/shared/agent/tests/llm-assert.d.ts +0 -11
- package/dist/shared/agent/tests/llm-assert.d.ts.map +0 -1
- package/dist/shared/agent/tests/llm-assert.js +0 -43
- package/dist/shared/agent/tests/llm-assert.js.map +0 -1
- package/dist/shared/agent/tool.factory.d.ts.map +0 -1
- package/dist/shared/agent/tool.factory.js.map +0 -1
- package/dist/shared/agent/tool.helpers.d.ts.map +0 -1
- package/dist/shared/agent/tool.helpers.js.map +0 -1
- package/dist/shared/agent/tool.registry.d.ts.map +0 -1
- package/dist/shared/agent/tool.registry.js.map +0 -1
- package/dist/shared/agent/tool.runtime.d.ts.map +0 -1
- package/dist/shared/agent/tool.runtime.js.map +0 -1
- package/dist/shared/agent/tool.scope.d.ts.map +0 -1
- package/dist/shared/agent/tool.scope.js.map +0 -1
- package/dist/shared/agent/utility.tools.d.ts.map +0 -1
- package/dist/shared/agent/utility.tools.js.map +0 -1
- package/dist/shared/assignment/network-assignment.policy.d.ts.map +0 -1
- package/dist/shared/assignment/network-assignment.policy.js.map +0 -1
- package/dist/shared/hyde/hyde.documents.d.ts.map +0 -1
- package/dist/shared/hyde/hyde.documents.js.map +0 -1
- package/dist/shared/hyde/hyde.env.d.ts.map +0 -1
- package/dist/shared/hyde/hyde.env.js.map +0 -1
- package/dist/shared/hyde/hyde.frame.d.ts.map +0 -1
- package/dist/shared/hyde/hyde.frame.js.map +0 -1
- package/dist/shared/hyde/hyde.generator.d.ts.map +0 -1
- package/dist/shared/hyde/hyde.generator.js.map +0 -1
- package/dist/shared/hyde/hyde.graph.d.ts.map +0 -1
- package/dist/shared/hyde/hyde.graph.js.map +0 -1
- package/dist/shared/hyde/hyde.state.d.ts.map +0 -1
- package/dist/shared/hyde/hyde.state.js.map +0 -1
- package/dist/shared/hyde/hyde.strategies.d.ts.map +0 -1
- package/dist/shared/hyde/hyde.strategies.js.map +0 -1
- package/dist/shared/hyde/hyde.validator.d.ts.map +0 -1
- package/dist/shared/hyde/hyde.validator.js.map +0 -1
- package/dist/shared/hyde/lens.inferrer.d.ts.map +0 -1
- package/dist/shared/hyde/lens.inferrer.js.map +0 -1
- package/dist/shared/interfaces/agent-dispatcher.interface.d.ts.map +0 -1
- package/dist/shared/interfaces/agent-dispatcher.interface.js.map +0 -1
- package/dist/shared/interfaces/agent.interface.d.ts.map +0 -1
- package/dist/shared/interfaces/agent.interface.js.map +0 -1
- package/dist/shared/interfaces/auth.interface.d.ts.map +0 -1
- package/dist/shared/interfaces/auth.interface.js.map +0 -1
- package/dist/shared/interfaces/cache.interface.d.ts.map +0 -1
- package/dist/shared/interfaces/cache.interface.js.map +0 -1
- package/dist/shared/interfaces/chat-message-writer.interface.d.ts.map +0 -1
- package/dist/shared/interfaces/chat-message-writer.interface.js.map +0 -1
- package/dist/shared/interfaces/chat-session.interface.d.ts.map +0 -1
- package/dist/shared/interfaces/chat-session.interface.js.map +0 -1
- package/dist/shared/interfaces/chat-summary.interface.d.ts.map +0 -1
- package/dist/shared/interfaces/chat-summary.interface.js.map +0 -1
- package/dist/shared/interfaces/connect-link.interface.d.ts.map +0 -1
- package/dist/shared/interfaces/connect-link.interface.js.map +0 -1
- package/dist/shared/interfaces/contact.interface.d.ts.map +0 -1
- package/dist/shared/interfaces/contact.interface.js.map +0 -1
- package/dist/shared/interfaces/database.interface.d.ts.map +0 -1
- package/dist/shared/interfaces/database.interface.js.map +0 -1
- package/dist/shared/interfaces/delivery-ledger.interface.d.ts.map +0 -1
- package/dist/shared/interfaces/delivery-ledger.interface.js.map +0 -1
- package/dist/shared/interfaces/discovery-run.interface.d.ts.map +0 -1
- package/dist/shared/interfaces/discovery-run.interface.js.map +0 -1
- package/dist/shared/interfaces/embedder.interface.d.ts.map +0 -1
- package/dist/shared/interfaces/embedder.interface.js.map +0 -1
- package/dist/shared/interfaces/enrichment-run.interface.d.ts.map +0 -1
- package/dist/shared/interfaces/enrichment-run.interface.js.map +0 -1
- package/dist/shared/interfaces/enrichment.interface.d.ts.map +0 -1
- package/dist/shared/interfaces/enrichment.interface.js.map +0 -1
- package/dist/shared/interfaces/integration.interface.d.ts.map +0 -1
- package/dist/shared/interfaces/integration.interface.js.map +0 -1
- package/dist/shared/interfaces/negotiation-events.interface.d.ts.map +0 -1
- package/dist/shared/interfaces/negotiation-events.interface.js.map +0 -1
- package/dist/shared/interfaces/negotiation-summary.interface.d.ts.map +0 -1
- package/dist/shared/interfaces/negotiation-summary.interface.js.map +0 -1
- package/dist/shared/interfaces/negotiator-memory.interface.d.ts.map +0 -1
- package/dist/shared/interfaces/negotiator-memory.interface.js.map +0 -1
- package/dist/shared/interfaces/question-generator.interface.d.ts.map +0 -1
- package/dist/shared/interfaces/question-generator.interface.js.map +0 -1
- package/dist/shared/interfaces/questioner.interface.d.ts.map +0 -1
- package/dist/shared/interfaces/questioner.interface.js.map +0 -1
- package/dist/shared/interfaces/queue.interface.d.ts.map +0 -1
- package/dist/shared/interfaces/queue.interface.js.map +0 -1
- package/dist/shared/interfaces/scraper.interface.d.ts.map +0 -1
- package/dist/shared/interfaces/scraper.interface.js.map +0 -1
- package/dist/shared/network/metadata.renderer.d.ts.map +0 -1
- package/dist/shared/network/metadata.renderer.js.map +0 -1
- package/dist/shared/observability/debug-meta.sanitizer.d.ts.map +0 -1
- package/dist/shared/observability/debug-meta.sanitizer.js.map +0 -1
- package/dist/shared/observability/log.d.ts.map +0 -1
- package/dist/shared/observability/log.js.map +0 -1
- package/dist/shared/observability/performance.d.ts.map +0 -1
- package/dist/shared/observability/performance.js.map +0 -1
- package/dist/shared/observability/protocol.logger.d.ts.map +0 -1
- package/dist/shared/observability/protocol.logger.js.map +0 -1
- package/dist/shared/observability/request-context.d.ts.map +0 -1
- package/dist/shared/observability/request-context.js.map +0 -1
- package/dist/shared/observability/trace.d.ts.map +0 -1
- package/dist/shared/observability/trace.js.map +0 -1
- package/dist/shared/schemas/chat-context.schema.d.ts.map +0 -1
- package/dist/shared/schemas/chat-context.schema.js.map +0 -1
- package/dist/shared/schemas/discovery-question.schema.d.ts.map +0 -1
- package/dist/shared/schemas/discovery-question.schema.js.map +0 -1
- package/dist/shared/schemas/identity.schema.d.ts.map +0 -1
- package/dist/shared/schemas/identity.schema.js.map +0 -1
- package/dist/shared/schemas/mcp-auth.schema.d.ts.map +0 -1
- package/dist/shared/schemas/mcp-auth.schema.js.map +0 -1
- package/dist/shared/schemas/negotiation-digest.schema.d.ts.map +0 -1
- package/dist/shared/schemas/negotiation-digest.schema.js.map +0 -1
- package/dist/shared/schemas/negotiation-state.schema.d.ts.map +0 -1
- package/dist/shared/schemas/negotiation-state.schema.js.map +0 -1
- package/dist/shared/schemas/network-assignment.schema.d.ts.map +0 -1
- package/dist/shared/schemas/network-assignment.schema.js.map +0 -1
- package/dist/shared/schemas/pending-question.schema.d.ts.map +0 -1
- package/dist/shared/schemas/pending-question.schema.js.map +0 -1
- package/dist/shared/schemas/question.schema.d.ts.map +0 -1
- package/dist/shared/schemas/question.schema.js.map +0 -1
- package/dist/shared/ui/lucide.icon-catalog.d.ts.map +0 -1
- package/dist/shared/ui/lucide.icon-catalog.js.map +0 -1
- package/dist/shared/utils/social-label.d.ts.map +0 -1
- package/dist/shared/utils/social-label.js.map +0 -1
- package/dist/shared/utils/telegram-handle.d.ts.map +0 -1
- package/dist/shared/utils/telegram-handle.js.map +0 -1
|
@@ -1,948 +1,5 @@
|
|
|
1
|
-
import { z } from 'zod';
|
|
2
|
-
import { success, error } from '../shared/agent/tool.helpers.js';
|
|
3
|
-
import { IndexNegotiator } from './negotiation.agent.js';
|
|
4
|
-
import { allowedActionsFor, isTerminalAction, readProtocolVersion, rejectActionFor, resolveSeat, seatViolationMessage } from './negotiation.protocol.js';
|
|
5
|
-
import { NEGOTIATION_ACTIONS } from '../shared/schemas/negotiation-state.schema.js';
|
|
6
|
-
import { protocolLogger } from '../shared/observability/protocol.logger.js';
|
|
7
|
-
import { focusedIntentId, focusedNetworkId } from '../shared/agent/tool.scope.js';
|
|
8
|
-
const logger = protocolLogger('ChatTools:Negotiation');
|
|
9
1
|
/**
|
|
10
|
-
*
|
|
11
|
-
*
|
|
12
|
-
* the system agent takes over as a fallback.
|
|
13
|
-
*
|
|
14
|
-
* Short enough that ambient opportunities materialize in minutes (not hours),
|
|
15
|
-
* long enough to cover two full polling cycles (30s * 2 = 60s) plus an agent
|
|
16
|
-
* subagent turn. 5 minutes gives generous headroom.
|
|
2
|
+
* Thin backward-compat shim — IND-550.
|
|
3
|
+
* Canonical location: negotiation/application/negotiation.tools.ts
|
|
17
4
|
*/
|
|
18
|
-
export
|
|
19
|
-
/**
|
|
20
|
-
* Pulls the negotiation's network from task metadata. Tasks created after the
|
|
21
|
-
* scope hardening carry `metadata.networkId` directly; older tasks only have
|
|
22
|
-
* the network embedded in the parked `turnContext.indexContext.networkId`.
|
|
23
|
-
* Returns `null` for legacy tasks where neither field is present — callers
|
|
24
|
-
* scoped by the request scope envelope must reject these defensively rather than
|
|
25
|
-
* fall through to a global view.
|
|
26
|
-
*/
|
|
27
|
-
function readTaskNetworkId(meta) {
|
|
28
|
-
if (!meta)
|
|
29
|
-
return null;
|
|
30
|
-
if (typeof meta.networkId === 'string' && meta.networkId.trim())
|
|
31
|
-
return meta.networkId;
|
|
32
|
-
const fromTurnContext = meta.turnContext?.indexContext?.networkId;
|
|
33
|
-
if (typeof fromTurnContext === 'string' && fromTurnContext.trim())
|
|
34
|
-
return fromTurnContext;
|
|
35
|
-
return null;
|
|
36
|
-
}
|
|
37
|
-
const SCOPE_DENIAL = 'Access denied: this negotiation is not in your bound network scope.';
|
|
38
|
-
const DIRECT_CONVERSATION_EVIDENCE_UNAVAILABLE = 'not_provided';
|
|
39
|
-
/**
|
|
40
|
-
* Builds additive, lifecycle-explicit narration metadata. Task completion only
|
|
41
|
-
* means the agents concluded; it never establishes owner acceptance or an H2H
|
|
42
|
-
* conversation.
|
|
43
|
-
*/
|
|
44
|
-
function buildLifecycleNarration(negotiationStatus, opportunity) {
|
|
45
|
-
const agentNegotiation = negotiationStatus === 'completed'
|
|
46
|
-
? 'concluded'
|
|
47
|
-
: negotiationStatus === 'active'
|
|
48
|
-
? 'in_progress'
|
|
49
|
-
: negotiationStatus === 'waiting_for_agent'
|
|
50
|
-
? 'awaiting_agent'
|
|
51
|
-
: 'unknown';
|
|
52
|
-
const common = {
|
|
53
|
-
agentNegotiation,
|
|
54
|
-
opportunityStatus: opportunity?.status ?? null,
|
|
55
|
-
ownerAction: opportunity?.acceptedByOwner ? 'accepted' : 'not_recorded',
|
|
56
|
-
directConversationEvidence: DIRECT_CONVERSATION_EVIDENCE_UNAVAILABLE,
|
|
57
|
-
};
|
|
58
|
-
switch (opportunity?.status) {
|
|
59
|
-
case 'pending':
|
|
60
|
-
return {
|
|
61
|
-
...common,
|
|
62
|
-
connectionState: 'potential_match_awaiting_owner_review',
|
|
63
|
-
lifecycleLabel: negotiationStatus === 'completed'
|
|
64
|
-
? "Agents concluded with a potential match; awaiting the owner's review."
|
|
65
|
-
: "A potential match is awaiting the owner's review.",
|
|
66
|
-
};
|
|
67
|
-
case 'accepted':
|
|
68
|
-
return opportunity.acceptedByOwner
|
|
69
|
-
? {
|
|
70
|
-
...common,
|
|
71
|
-
connectionState: 'owner_accepted',
|
|
72
|
-
lifecycleLabel: 'The owner explicitly accepted this opportunity.',
|
|
73
|
-
}
|
|
74
|
-
: {
|
|
75
|
-
...common,
|
|
76
|
-
connectionState: 'accepted_without_owner_evidence',
|
|
77
|
-
lifecycleLabel: 'The opportunity is accepted; this result does not record an owner acceptance.',
|
|
78
|
-
};
|
|
79
|
-
case 'rejected':
|
|
80
|
-
return {
|
|
81
|
-
...common,
|
|
82
|
-
connectionState: 'rejected',
|
|
83
|
-
lifecycleLabel: 'The opportunity was rejected; no connection was established.',
|
|
84
|
-
};
|
|
85
|
-
case 'stalled':
|
|
86
|
-
return {
|
|
87
|
-
...common,
|
|
88
|
-
connectionState: 'negotiation_stalled',
|
|
89
|
-
lifecycleLabel: 'The agent negotiation stalled; no connection was established.',
|
|
90
|
-
};
|
|
91
|
-
case 'draft':
|
|
92
|
-
return {
|
|
93
|
-
...common,
|
|
94
|
-
connectionState: 'draft_not_sent',
|
|
95
|
-
lifecycleLabel: 'The opportunity is still a draft; it has not been sent or accepted.',
|
|
96
|
-
};
|
|
97
|
-
case 'expired':
|
|
98
|
-
return {
|
|
99
|
-
...common,
|
|
100
|
-
connectionState: 'expired',
|
|
101
|
-
lifecycleLabel: 'The opportunity expired; no connection was established.',
|
|
102
|
-
};
|
|
103
|
-
case 'negotiating':
|
|
104
|
-
return {
|
|
105
|
-
...common,
|
|
106
|
-
connectionState: 'agents_negotiating',
|
|
107
|
-
lifecycleLabel: 'The agents are still negotiating; no owner decision is recorded.',
|
|
108
|
-
};
|
|
109
|
-
case 'latent':
|
|
110
|
-
return {
|
|
111
|
-
...common,
|
|
112
|
-
connectionState: 'latent',
|
|
113
|
-
lifecycleLabel: 'The potential match is latent; no owner decision is recorded.',
|
|
114
|
-
};
|
|
115
|
-
default:
|
|
116
|
-
return {
|
|
117
|
-
...common,
|
|
118
|
-
connectionState: 'unknown',
|
|
119
|
-
lifecycleLabel: negotiationStatus === 'completed'
|
|
120
|
-
? 'The agent negotiation concluded; the current opportunity lifecycle is unavailable.'
|
|
121
|
-
: 'The current opportunity lifecycle is unavailable.',
|
|
122
|
-
};
|
|
123
|
-
}
|
|
124
|
-
}
|
|
125
|
-
/** Reads lifecycle evidence without making older host adapters mandatory. */
|
|
126
|
-
async function readOpportunityLifecycles(database, opportunityIds, ownerUserId) {
|
|
127
|
-
if (opportunityIds.length === 0 || !database.getOpportunityLifecyclesForNegotiations)
|
|
128
|
-
return {};
|
|
129
|
-
try {
|
|
130
|
-
return await database.getOpportunityLifecyclesForNegotiations(opportunityIds, ownerUserId);
|
|
131
|
-
}
|
|
132
|
-
catch (err) {
|
|
133
|
-
logger.warn('Failed to load opportunity lifecycle for negotiation narration', { err });
|
|
134
|
-
return {};
|
|
135
|
-
}
|
|
136
|
-
}
|
|
137
|
-
/** Extracts the ordered NegotiationTurn list from A2A message data parts. */
|
|
138
|
-
function turnsFromMessages(messages) {
|
|
139
|
-
return messages
|
|
140
|
-
.map((m) => {
|
|
141
|
-
const dp = m.parts?.find((p) => p.kind === 'data');
|
|
142
|
-
return dp?.data;
|
|
143
|
-
})
|
|
144
|
-
.filter(Boolean);
|
|
145
|
-
}
|
|
146
|
-
/**
|
|
147
|
-
* Creates negotiation MCP tools for external agent access.
|
|
148
|
-
* Exposes negotiation state for listing, reading, and responding to bilateral negotiations.
|
|
149
|
-
*/
|
|
150
|
-
export function createNegotiationTools(defineTool, deps) {
|
|
151
|
-
const { negotiationDatabase } = deps;
|
|
152
|
-
const list_negotiations = defineTool({
|
|
153
|
-
name: 'list_negotiations',
|
|
154
|
-
description: 'List bilateral negotiations the authenticated user is involved in, either as the source (initiator) or candidate (responder). ' +
|
|
155
|
-
'Negotiations are turn-based exchanges where two AI agents negotiate on behalf of their users to determine if there is a ' +
|
|
156
|
-
'mutual opportunity for collaboration.\n\n' +
|
|
157
|
-
'**Statuses:**\n' +
|
|
158
|
-
'- `active` — Negotiation is in progress, agents are exchanging turns.\n' +
|
|
159
|
-
'- `waiting_for_agent` — The graph has yielded and is waiting for an agent response (e.g. from the user via respond_to_negotiation) or a timeout.\n' +
|
|
160
|
-
'- `completed` — The agent negotiation has concluded (agent-side accept/reject, or turn cap). This is not a completed connection or an owner decision.\n\n' +
|
|
161
|
-
'**Lifecycle narration:** Every result includes additive `lifecycle` fields that distinguish the agent-negotiation state, ' +
|
|
162
|
-
'current opportunity status, and persisted owner acceptance. Agent-side `accept` means only that agents found a potential match; ' +
|
|
163
|
-
'`pending` still awaits owner review. `directConversationEvidence` is `not_provided`, so this tool never establishes that an H2H message thread exists.\n\n' +
|
|
164
|
-
'**When to use:** To see ongoing and past negotiations, check which negotiations need attention, ' +
|
|
165
|
-
'or find a negotiation ID for get_negotiation or respond_to_negotiation.',
|
|
166
|
-
querySchema: z.object({
|
|
167
|
-
status: z.enum(['active', 'waiting_for_agent', 'completed', 'all']).optional()
|
|
168
|
-
.describe('Filter by negotiation status. Omit or use "all" to return all negotiations.'),
|
|
169
|
-
scope: z.enum(['signal', 'all']).optional()
|
|
170
|
-
.describe('Scope to the pinned signal (requires an intent-pinned session), or pass "all" for the full negotiation history.'),
|
|
171
|
-
since: z.string().datetime().optional()
|
|
172
|
-
.describe('ISO 8601 date-time. Only return negotiations created at or after this timestamp.'),
|
|
173
|
-
limit: z.number().int().min(1).max(100).optional()
|
|
174
|
-
.describe('Maximum negotiations to return per page (1-100). Omit to return all.'),
|
|
175
|
-
page: z.number().int().min(1).optional()
|
|
176
|
-
.describe('Page number (1-based). Only used when limit is provided. Defaults to 1.'),
|
|
177
|
-
detail: z.enum(['summary', 'narrative']).optional()
|
|
178
|
-
.describe('Response detail level. Omit or use "summary" for the default fields. ' +
|
|
179
|
-
'Use "narrative" to receive additional context per negotiation suitable for ' +
|
|
180
|
-
'composing a digest or field report: indexContext (the community/network prompt ' +
|
|
181
|
-
'that seeded the negotiation), recentTurns (last 3 turns with action + message), ' +
|
|
182
|
-
'and outcome (for completed negotiations). These fields are populated from data ' +
|
|
183
|
-
'already loaded for the listing, so the extra cost is minimal.'),
|
|
184
|
-
}),
|
|
185
|
-
handler: async ({ context, query }) => {
|
|
186
|
-
try {
|
|
187
|
-
// Map tool status filter to task state query
|
|
188
|
-
const stateFilter = query.status && query.status !== 'all' ? query.status : undefined;
|
|
189
|
-
// For 'active', query 'working' state tasks
|
|
190
|
-
const dbState = stateFilter === 'active' ? 'working'
|
|
191
|
-
: stateFilter === 'waiting_for_agent' ? 'waiting_for_agent'
|
|
192
|
-
: stateFilter === 'completed' ? 'completed'
|
|
193
|
-
: undefined;
|
|
194
|
-
const tasks = await negotiationDatabase.getTasksForUser(context.userId, dbState ? { state: dbState } : undefined);
|
|
195
|
-
const opportunityIds = [...new Set(tasks
|
|
196
|
-
.map((task) => task.metadata?.opportunityId)
|
|
197
|
-
.filter((opportunityId) => typeof opportunityId === 'string' && opportunityId.trim().length > 0)
|
|
198
|
-
.map((opportunityId) => opportunityId.trim()))];
|
|
199
|
-
const opportunityLifecycles = await readOpportunityLifecycles(negotiationDatabase, opportunityIds, context.userId);
|
|
200
|
-
const scopedNetworkId = focusedNetworkId(context);
|
|
201
|
-
const pinnedIntentId = focusedIntentId(context);
|
|
202
|
-
const effectiveScope = query.scope ?? (pinnedIntentId ? 'signal' : 'all');
|
|
203
|
-
if (effectiveScope === 'signal' && !pinnedIntentId) {
|
|
204
|
-
return error('Signal scope requires a pinned intent.');
|
|
205
|
-
}
|
|
206
|
-
const signalIntentIdsByOpportunity = effectiveScope === 'signal'
|
|
207
|
-
? await negotiationDatabase.getIntentIdsForOpportunities(opportunityIds, context.userId)
|
|
208
|
-
: null;
|
|
209
|
-
const scopeMetadata = effectiveScope === 'signal'
|
|
210
|
-
? { scope: 'signal', intentId: pinnedIntentId }
|
|
211
|
-
: { scope: 'all' };
|
|
212
|
-
const negotiations = await Promise.all(tasks.map(async (task) => {
|
|
213
|
-
const meta = task.metadata;
|
|
214
|
-
if (meta?.type !== 'negotiation')
|
|
215
|
-
return null;
|
|
216
|
-
// Network-scope filter: when caller's API key carries a network-bound
|
|
217
|
-
// agent, drop tasks whose network differs (or whose network we cannot
|
|
218
|
-
// determine — defense in depth for legacy tasks).
|
|
219
|
-
if (scopedNetworkId) {
|
|
220
|
-
const taskNetworkId = readTaskNetworkId(meta);
|
|
221
|
-
if (taskNetworkId !== scopedNetworkId)
|
|
222
|
-
return null;
|
|
223
|
-
}
|
|
224
|
-
// Intent-scope filter: a pinned negotiator workspace only shows
|
|
225
|
-
// opportunity-bound tasks whose actor intent belongs to this user and
|
|
226
|
-
// matches the pinned signal. Tasks without resolvable provenance are
|
|
227
|
-
// dropped rather than widened into the user's full history.
|
|
228
|
-
const opportunityId = typeof meta.opportunityId === 'string' ? meta.opportunityId.trim() : '';
|
|
229
|
-
if (effectiveScope === 'signal'
|
|
230
|
-
&& (!opportunityId || signalIntentIdsByOpportunity?.[opportunityId] !== pinnedIntentId)) {
|
|
231
|
-
return null;
|
|
232
|
-
}
|
|
233
|
-
const isSource = meta.sourceUserId === context.userId;
|
|
234
|
-
const counterpartyId = isSource ? meta.candidateUserId : meta.sourceUserId;
|
|
235
|
-
// Get messages for preview (and turns when narrative detail requested)
|
|
236
|
-
const messages = await negotiationDatabase.getMessagesForConversation(task.conversationId);
|
|
237
|
-
const lastMessage = messages[messages.length - 1];
|
|
238
|
-
const lastTurnData = lastMessage
|
|
239
|
-
? lastMessage.parts?.find(p => p.kind === 'data')?.data
|
|
240
|
-
: undefined;
|
|
241
|
-
// Determine whose turn it is from the last message's sender — not
|
|
242
|
-
// parity, which misattributes across continuation sessions. Rows
|
|
243
|
-
// without senderId (legacy) fall back to parity.
|
|
244
|
-
const turnCount = messages.length;
|
|
245
|
-
const lastSenderId = turnCount > 0 ? messages[turnCount - 1].senderId : null;
|
|
246
|
-
const currentSpeaker = lastSenderId
|
|
247
|
-
? (lastSenderId === `agent:${meta.sourceUserId}` ? 'candidate' : 'source')
|
|
248
|
-
: (turnCount % 2 === 0 ? 'source' : 'candidate');
|
|
249
|
-
// Map task state to tool status
|
|
250
|
-
const status = task.state === 'working' ? 'active'
|
|
251
|
-
: task.state === 'waiting_for_agent' ? 'waiting_for_agent'
|
|
252
|
-
: task.state === 'completed' ? 'completed'
|
|
253
|
-
: task.state;
|
|
254
|
-
const isUsersTurn = status !== 'completed' &&
|
|
255
|
-
((isSource && currentSpeaker === 'source') || (!isSource && currentSpeaker === 'candidate'));
|
|
256
|
-
const base = {
|
|
257
|
-
id: task.id,
|
|
258
|
-
counterpartyId: counterpartyId ?? 'unknown',
|
|
259
|
-
role: isSource ? 'source' : 'candidate',
|
|
260
|
-
turnCount,
|
|
261
|
-
status,
|
|
262
|
-
isUsersTurn,
|
|
263
|
-
isContinuation: meta.isContinuation ?? false,
|
|
264
|
-
priorTurnCount: meta.priorTurnCount ?? 0,
|
|
265
|
-
latestAction: lastTurnData?.action ?? null,
|
|
266
|
-
latestActionActor: 'agent',
|
|
267
|
-
latestMessagePreview: lastTurnData?.message ?? null,
|
|
268
|
-
lifecycle: buildLifecycleNarration(status, opportunityLifecycles[opportunityId]),
|
|
269
|
-
createdAt: task.createdAt,
|
|
270
|
-
updatedAt: task.updatedAt,
|
|
271
|
-
};
|
|
272
|
-
if (query.detail !== 'narrative')
|
|
273
|
-
return base;
|
|
274
|
-
// ── Narrative extras (messages already loaded — no extra DB cost) ──
|
|
275
|
-
const RECENT_TURNS_LIMIT = 3;
|
|
276
|
-
const recentMessages = messages.slice(-RECENT_TURNS_LIMIT);
|
|
277
|
-
const recentTurns = recentMessages.map((m, sliceIdx) => {
|
|
278
|
-
const absoluteIdx = messages.length - recentMessages.length + sliceIdx;
|
|
279
|
-
const speaker = m.senderId
|
|
280
|
-
? (m.senderId === `agent:${meta.sourceUserId}` ? 'source' : 'candidate')
|
|
281
|
-
: (absoluteIdx % 2 === 0 ? 'source' : 'candidate');
|
|
282
|
-
const td = m.parts?.find(p => p.kind === 'data')?.data;
|
|
283
|
-
return {
|
|
284
|
-
turnNumber: absoluteIdx + 1,
|
|
285
|
-
speaker,
|
|
286
|
-
role: speaker === (isSource ? 'source' : 'candidate') ? 'own' : 'other',
|
|
287
|
-
action: td?.action ?? 'unknown',
|
|
288
|
-
actionActor: 'agent',
|
|
289
|
-
message: td?.message ?? null,
|
|
290
|
-
};
|
|
291
|
-
});
|
|
292
|
-
const indexContext = meta.turnContext?.indexContext ?? null;
|
|
293
|
-
// Outcome artifact — only meaningful for completed negotiations
|
|
294
|
-
let outcome = null;
|
|
295
|
-
if (status === 'completed') {
|
|
296
|
-
const artifacts = await negotiationDatabase.getArtifactsForTask(task.id);
|
|
297
|
-
const outcomeArtifact = artifacts.find(a => a.name === 'negotiation-outcome');
|
|
298
|
-
outcome = outcomeArtifact
|
|
299
|
-
? (outcomeArtifact.parts?.find(p => p.kind === 'data')?.data ?? null)
|
|
300
|
-
: null;
|
|
301
|
-
}
|
|
302
|
-
return { ...base, indexContext, recentTurns, outcome };
|
|
303
|
-
}));
|
|
304
|
-
let filtered = negotiations.filter(Boolean);
|
|
305
|
-
if (query.since) {
|
|
306
|
-
const sinceMs = new Date(query.since).getTime();
|
|
307
|
-
filtered = filtered.filter(n => new Date(n.createdAt).getTime() >= sinceMs);
|
|
308
|
-
}
|
|
309
|
-
const shouldPaginate = query.limit !== undefined;
|
|
310
|
-
if (shouldPaginate) {
|
|
311
|
-
const limit = query.limit;
|
|
312
|
-
const page = query.page ?? 1;
|
|
313
|
-
const offset = (page - 1) * limit;
|
|
314
|
-
const paged = filtered.slice(offset, offset + limit);
|
|
315
|
-
return success({
|
|
316
|
-
...scopeMetadata,
|
|
317
|
-
count: paged.length,
|
|
318
|
-
totalCount: filtered.length,
|
|
319
|
-
limit,
|
|
320
|
-
page,
|
|
321
|
-
totalPages: Math.ceil(filtered.length / limit),
|
|
322
|
-
negotiations: paged,
|
|
323
|
-
});
|
|
324
|
-
}
|
|
325
|
-
return success({
|
|
326
|
-
...scopeMetadata,
|
|
327
|
-
count: filtered.length,
|
|
328
|
-
negotiations: filtered,
|
|
329
|
-
});
|
|
330
|
-
}
|
|
331
|
-
catch (err) {
|
|
332
|
-
logger.error('Failed to list negotiations', { err });
|
|
333
|
-
return error('Failed to list negotiations. Please try again.');
|
|
334
|
-
}
|
|
335
|
-
},
|
|
336
|
-
});
|
|
337
|
-
const get_negotiation = defineTool({
|
|
338
|
-
name: 'get_negotiation',
|
|
339
|
-
description: 'Get the full details of a specific negotiation, including all turns, messages, counterparty info, and current state. ' +
|
|
340
|
-
'Negotiations are bilateral exchanges where two AI agents negotiate on behalf of users. Each turn contains an action ' +
|
|
341
|
-
'(propose, accept, reject, counter, question), an assessment with reasoning and suggested roles, and an optional message.\n\n' +
|
|
342
|
-
'**Access control:** You must be a party to the negotiation (source or candidate) to view it.\n\n' +
|
|
343
|
-
'**Statuses:** `active` — in progress. `waiting_for_agent` — waiting for an agent response or timeout. `completed` — the agents concluded, not that the owner accepted or a connection/message thread exists.\n\n' +
|
|
344
|
-
'**Lifecycle narration:** The additive `lifecycle` object is authoritative for user-facing wording. A turn action of `accept` is agent-side; ' +
|
|
345
|
-
'only `lifecycle.ownerAction=accepted` records this owner as the human acceptor. `conversationType=agent_negotiation` identifies the returned ' +
|
|
346
|
-
'conversationId as the A2A negotiation transcript; this result does not provide H2H conversation evidence.\n\n' +
|
|
347
|
-
'**When to use:** To review the full negotiation history before responding, to understand why the agents ' +
|
|
348
|
-
'accepted or rejected a potential match, or to see the current state of an active negotiation.\n\n' +
|
|
349
|
-
'**Negotiation-turn-mode usage.** If you are running as a silent background subagent (dispatched by the ' +
|
|
350
|
-
"openclaw runtime's poller in response to a claimed negotiation turn), call this tool FIRST with the " +
|
|
351
|
-
'negotiationId from your task prompt. This returns the current state, both parties\' context, and the ' +
|
|
352
|
-
'history of turns so far. Ground your response in the caller\'s profile (read_user_contexts) and intents ' +
|
|
353
|
-
'(read_intents) before deciding on a turn action. Do not produce user-facing output in this mode.',
|
|
354
|
-
querySchema: z.object({
|
|
355
|
-
negotiationId: z.string().describe('The negotiation task ID (from list_negotiations results).'),
|
|
356
|
-
}),
|
|
357
|
-
handler: async ({ context, query }) => {
|
|
358
|
-
try {
|
|
359
|
-
const task = await negotiationDatabase.getTask(query.negotiationId);
|
|
360
|
-
if (!task) {
|
|
361
|
-
return error('Negotiation not found.');
|
|
362
|
-
}
|
|
363
|
-
const meta = task.metadata;
|
|
364
|
-
if (meta?.type !== 'negotiation') {
|
|
365
|
-
return error('Negotiation not found.');
|
|
366
|
-
}
|
|
367
|
-
// Network-scope check: a network-bound agent must not read negotiations
|
|
368
|
-
// outside its bound network. Run before the participant check so we
|
|
369
|
-
// don't leak existence-vs-membership signal across scopes.
|
|
370
|
-
const scopedNetworkId = focusedNetworkId(context);
|
|
371
|
-
if (scopedNetworkId) {
|
|
372
|
-
const taskNetworkId = readTaskNetworkId(meta);
|
|
373
|
-
if (taskNetworkId !== scopedNetworkId) {
|
|
374
|
-
return error(SCOPE_DENIAL);
|
|
375
|
-
}
|
|
376
|
-
}
|
|
377
|
-
// Access control: user must be source or candidate
|
|
378
|
-
const isSource = meta.sourceUserId === context.userId;
|
|
379
|
-
const isCandidate = meta.candidateUserId === context.userId;
|
|
380
|
-
if (!isSource && !isCandidate) {
|
|
381
|
-
return error('Access denied: you are not a party to this negotiation.');
|
|
382
|
-
}
|
|
383
|
-
const counterpartyId = isSource ? meta.candidateUserId : meta.sourceUserId;
|
|
384
|
-
// Project absolute turn context (source/candidate) into own/other
|
|
385
|
-
// perspective for the caller. Mirrors what the in-process system
|
|
386
|
-
// agent receives as NegotiationAgentInput — identical context means
|
|
387
|
-
// identical deliberation on both paths.
|
|
388
|
-
let negotiationContext = null;
|
|
389
|
-
if (meta.turnContext) {
|
|
390
|
-
const tc = meta.turnContext;
|
|
391
|
-
negotiationContext = {
|
|
392
|
-
ownUser: isSource ? tc.sourceUser : tc.candidateUser,
|
|
393
|
-
otherUser: isSource ? tc.candidateUser : tc.sourceUser,
|
|
394
|
-
indexContext: tc.indexContext,
|
|
395
|
-
seedAssessment: tc.seedAssessment,
|
|
396
|
-
isDiscoverer: isSource,
|
|
397
|
-
...(tc.discoveryQuery && { discoveryQuery: tc.discoveryQuery }),
|
|
398
|
-
};
|
|
399
|
-
}
|
|
400
|
-
const lifecycleOpportunityId = meta.opportunityId?.trim() || undefined;
|
|
401
|
-
// Load messages, artifacts, and the independently persisted opportunity lifecycle.
|
|
402
|
-
const [messages, artifacts, opportunityLifecycles] = await Promise.all([
|
|
403
|
-
negotiationDatabase.getMessagesForConversation(task.conversationId),
|
|
404
|
-
negotiationDatabase.getArtifactsForTask(task.id),
|
|
405
|
-
readOpportunityLifecycles(negotiationDatabase, lifecycleOpportunityId ? [lifecycleOpportunityId] : [], context.userId),
|
|
406
|
-
]);
|
|
407
|
-
// Parse turns from messages (speaker from senderId, not parity —
|
|
408
|
-
// continuations can start with either side speaking first)
|
|
409
|
-
const turns = messages.map((m, idx) => {
|
|
410
|
-
const dataPart = m.parts?.find(p => p.kind === 'data');
|
|
411
|
-
const turnData = dataPart?.data;
|
|
412
|
-
const turnNumber = idx + 1;
|
|
413
|
-
const speaker = m.senderId
|
|
414
|
-
? (m.senderId === `agent:${meta.sourceUserId}` ? 'source' : 'candidate')
|
|
415
|
-
: (turnNumber % 2 === 1 ? 'source' : 'candidate');
|
|
416
|
-
return {
|
|
417
|
-
turnNumber,
|
|
418
|
-
speaker,
|
|
419
|
-
senderId: m.senderId,
|
|
420
|
-
action: turnData?.action ?? 'unknown',
|
|
421
|
-
actionActor: 'agent',
|
|
422
|
-
reasoning: turnData?.assessment?.reasoning ?? null,
|
|
423
|
-
suggestedRoles: turnData?.assessment?.suggestedRoles ?? null,
|
|
424
|
-
message: turnData?.message ?? null,
|
|
425
|
-
createdAt: m.createdAt,
|
|
426
|
-
};
|
|
427
|
-
});
|
|
428
|
-
// Extract outcome from artifacts if completed
|
|
429
|
-
const outcomeArtifact = artifacts.find(a => a.name === 'negotiation-outcome');
|
|
430
|
-
const outcome = outcomeArtifact
|
|
431
|
-
? outcomeArtifact.parts?.find(p => p.kind === 'data')?.data
|
|
432
|
-
: null;
|
|
433
|
-
// Determine whose turn it is (last sender's counterpart, not parity;
|
|
434
|
-
// rows without senderId fall back to parity)
|
|
435
|
-
const turnCount = messages.length;
|
|
436
|
-
const lastSenderId = turnCount > 0 ? messages[turnCount - 1].senderId : null;
|
|
437
|
-
const currentSpeaker = lastSenderId
|
|
438
|
-
? (lastSenderId === `agent:${meta.sourceUserId}` ? 'candidate' : 'source')
|
|
439
|
-
: (turnCount % 2 === 0 ? 'source' : 'candidate');
|
|
440
|
-
const status = task.state === 'working' ? 'active'
|
|
441
|
-
: task.state === 'waiting_for_agent' ? 'waiting_for_agent'
|
|
442
|
-
: task.state === 'completed' ? 'completed'
|
|
443
|
-
: task.state;
|
|
444
|
-
const isUsersTurn = status !== 'completed' &&
|
|
445
|
-
((isSource && currentSpeaker === 'source') || (!isSource && currentSpeaker === 'candidate'));
|
|
446
|
-
const isContinuation = meta.isContinuation ?? false;
|
|
447
|
-
const priorTurnCount = meta.priorTurnCount ?? 0;
|
|
448
|
-
// Seat + protocol version (v2 client-advocate): announce the caller's
|
|
449
|
-
// seat and the actions it may submit so agents don't guess.
|
|
450
|
-
const protocolVersion = readProtocolVersion(meta) ?? 'v1';
|
|
451
|
-
const seat = resolveSeat(context.userId, meta);
|
|
452
|
-
return success({
|
|
453
|
-
id: task.id,
|
|
454
|
-
conversationId: task.conversationId,
|
|
455
|
-
conversationType: 'agent_negotiation',
|
|
456
|
-
status,
|
|
457
|
-
role: isSource ? 'source' : 'candidate',
|
|
458
|
-
seat,
|
|
459
|
-
protocolVersion,
|
|
460
|
-
allowedActions: allowedActionsFor(protocolVersion, seat),
|
|
461
|
-
counterpartyId: counterpartyId ?? 'unknown',
|
|
462
|
-
turnCount,
|
|
463
|
-
isUsersTurn,
|
|
464
|
-
isContinuation,
|
|
465
|
-
priorTurnCount,
|
|
466
|
-
turnsAdded: turnCount - priorTurnCount,
|
|
467
|
-
turns,
|
|
468
|
-
outcome,
|
|
469
|
-
lifecycle: buildLifecycleNarration(status, lifecycleOpportunityId ? opportunityLifecycles[lifecycleOpportunityId] : undefined),
|
|
470
|
-
context: negotiationContext,
|
|
471
|
-
createdAt: task.createdAt,
|
|
472
|
-
updatedAt: task.updatedAt,
|
|
473
|
-
});
|
|
474
|
-
}
|
|
475
|
-
catch (err) {
|
|
476
|
-
logger.error('Failed to get negotiation', { err });
|
|
477
|
-
return error('Failed to get negotiation. Please try again.');
|
|
478
|
-
}
|
|
479
|
-
},
|
|
480
|
-
});
|
|
481
|
-
const respond_to_negotiation = defineTool({
|
|
482
|
-
name: 'respond_to_negotiation',
|
|
483
|
-
description: 'Respond to a negotiation that is waiting for agent input. This tool allows users to influence the negotiation ' +
|
|
484
|
-
'by accepting, rejecting, countering, or asking a clarifying question.\n\n' +
|
|
485
|
-
'**Turn-based model:** Negotiations alternate between source and candidate agents. When the graph yields with ' +
|
|
486
|
-
'`waiting_for_agent` status, the user whose turn it is can respond.\n\n' +
|
|
487
|
-
'**Valid actions depend on the negotiation protocol version and your seat** — call get_negotiation first: ' +
|
|
488
|
-
'its `seat`, `protocolVersion`, and `allowedActions` fields tell you exactly what you may submit.\n\n' +
|
|
489
|
-
'**v1 negotiations (legacy):** `propose | accept | reject | counter | question` — on the first turn the action MUST be `propose`.\n\n' +
|
|
490
|
-
'**v2 negotiations (client-advocate seat rules):**\n' +
|
|
491
|
-
'- Initiator seat (`outreach | counter | question | withdraw`): you reached out — you can NEVER accept. ' +
|
|
492
|
-
'`outreach` opens the negotiation; `withdraw` ends it without an opportunity.\n' +
|
|
493
|
-
'- Counterparty seat (`accept | decline | counter | question`): only your seat can `accept` (finalizes an opportunity); ' +
|
|
494
|
-
'`decline` ends the negotiation without one.\n\n' +
|
|
495
|
-
'- `counter` — Counter with a message (message is required). The negotiation continues.\n' +
|
|
496
|
-
'- `question` — Ask the other side a clarifying question (message is required). The negotiation continues.\n\n' +
|
|
497
|
-
'**What happens after:** Terminal actions (accept/reject/withdraw/decline) finalize the negotiation immediately. ' +
|
|
498
|
-
'Counter/question continues — if the counterparty has an agent, the negotiation yields again; otherwise the AI agent responds inline.\n\n' +
|
|
499
|
-
'**Silent-subagent response contract.** In negotiation-turn mode, submit exactly ONE call to this tool ' +
|
|
500
|
-
'per dispatch with an action from your seat\'s allowed set and the assessment (reasoning + suggestedRoles). ' +
|
|
501
|
-
'If the decision is ambiguous, pick the most conservative action — usually `counter` with specific objections. ' +
|
|
502
|
-
'Do not ask the user clarifying questions; you are authorized to act on their behalf within the scope granted to your agent.',
|
|
503
|
-
querySchema: z.object({
|
|
504
|
-
negotiationId: z.string().describe('The negotiation task ID to respond to.'),
|
|
505
|
-
action: z.enum(NEGOTIATION_ACTIONS).describe('The response action. Must be within your seat\'s allowedActions (see get_negotiation). v1 first turn MUST be "propose"; v2 initiator first turn MUST be "outreach".'),
|
|
506
|
-
reasoning: z.string().describe('Why you are taking this action — your assessment of the opportunity.'),
|
|
507
|
-
suggestedRoles: z.object({
|
|
508
|
-
ownUser: z.enum(['agent', 'patient', 'peer']).describe('Suggested role for your user in this opportunity.'),
|
|
509
|
-
otherUser: z.enum(['agent', 'patient', 'peer']).describe('Suggested role for the other user in this opportunity.'),
|
|
510
|
-
}).describe('Role suggestions for both parties.'),
|
|
511
|
-
message: z.string().optional().describe('Required for "counter" and "question" actions. Your message explaining what you want to change or clarify.'),
|
|
512
|
-
}),
|
|
513
|
-
handler: async ({ context, query }) => {
|
|
514
|
-
try {
|
|
515
|
-
const task = await negotiationDatabase.getTask(query.negotiationId);
|
|
516
|
-
if (!task) {
|
|
517
|
-
return error('Negotiation not found.');
|
|
518
|
-
}
|
|
519
|
-
const meta = task.metadata;
|
|
520
|
-
if (meta?.type !== 'negotiation') {
|
|
521
|
-
return error('Negotiation not found.');
|
|
522
|
-
}
|
|
523
|
-
// Network-scope check (mirrors get_negotiation): a network-bound agent
|
|
524
|
-
// must not act on negotiations outside its bound network.
|
|
525
|
-
const scopedNetworkId = focusedNetworkId(context);
|
|
526
|
-
if (scopedNetworkId) {
|
|
527
|
-
const taskNetworkId = readTaskNetworkId(meta);
|
|
528
|
-
if (taskNetworkId !== scopedNetworkId) {
|
|
529
|
-
return error(SCOPE_DENIAL);
|
|
530
|
-
}
|
|
531
|
-
}
|
|
532
|
-
// Validate negotiation is waiting for agent input (or claimed via polling)
|
|
533
|
-
if (task.state !== 'waiting_for_agent' && task.state !== 'claimed') {
|
|
534
|
-
return error(`Negotiation is not waiting for a response. Current status: ${task.state}`);
|
|
535
|
-
}
|
|
536
|
-
// Access control: user must be a party
|
|
537
|
-
const isSource = meta.sourceUserId === context.userId;
|
|
538
|
-
const isCandidate = meta.candidateUserId === context.userId;
|
|
539
|
-
if (!isSource && !isCandidate) {
|
|
540
|
-
return error('Access denied: you are not a party to this negotiation.');
|
|
541
|
-
}
|
|
542
|
-
// Seat + version validation (v2 client-advocate): the submitted action
|
|
543
|
-
// must be within the caller's seat vocabulary. v1 tasks accept the
|
|
544
|
-
// legacy vocabulary unchanged (grandfathered).
|
|
545
|
-
const protocolVersion = readProtocolVersion(meta) ?? 'v1';
|
|
546
|
-
const seat = resolveSeat(context.userId, meta);
|
|
547
|
-
if (!allowedActionsFor(protocolVersion, seat).includes(query.action)) {
|
|
548
|
-
return error(seatViolationMessage(query.action, seat, protocolVersion));
|
|
549
|
-
}
|
|
550
|
-
// Determine whose turn it is from the last message's sender — not
|
|
551
|
-
// parity, which misattributes across continuation sessions. Rows
|
|
552
|
-
// without senderId (legacy) fall back to the parity heuristic.
|
|
553
|
-
const messages = await negotiationDatabase.getMessagesForConversation(task.conversationId);
|
|
554
|
-
const turnCount = messages.length;
|
|
555
|
-
const lastSenderId = turnCount > 0 ? messages[turnCount - 1].senderId : null;
|
|
556
|
-
const paritySpeaker = turnCount % 2 === 0 ? 'source' : 'candidate';
|
|
557
|
-
const isUsersTurn = lastSenderId
|
|
558
|
-
? lastSenderId !== `agent:${context.userId}`
|
|
559
|
-
: ((isSource && paritySpeaker === 'source') || (!isSource && paritySpeaker === 'candidate'));
|
|
560
|
-
if (!isUsersTurn) {
|
|
561
|
-
return error('It is not your turn to respond in this negotiation.');
|
|
562
|
-
}
|
|
563
|
-
// The caller is the current speaker (verified above).
|
|
564
|
-
const currentSpeaker = isSource ? 'source' : 'candidate';
|
|
565
|
-
// Validate counter/question has a message
|
|
566
|
-
if ((query.action === 'counter' || query.action === 'question') && !query.message?.trim()) {
|
|
567
|
-
return error(`A message is required when using "${query.action}". Explain what you want to change or clarify.`);
|
|
568
|
-
}
|
|
569
|
-
// ── Cancel pending timeout ──
|
|
570
|
-
if (deps.negotiationTimeoutQueue) {
|
|
571
|
-
await deps.negotiationTimeoutQueue.cancelTimeout(task.id);
|
|
572
|
-
}
|
|
573
|
-
// ── Build and persist the external agent's turn ──
|
|
574
|
-
const turnData = {
|
|
575
|
-
action: query.action,
|
|
576
|
-
assessment: {
|
|
577
|
-
reasoning: query.reasoning,
|
|
578
|
-
suggestedRoles: query.suggestedRoles,
|
|
579
|
-
},
|
|
580
|
-
...(query.message ? { message: query.message } : {}),
|
|
581
|
-
};
|
|
582
|
-
const senderId = `agent:${context.userId}`;
|
|
583
|
-
const turnMessage = await negotiationDatabase.createMessage({
|
|
584
|
-
conversationId: task.conversationId,
|
|
585
|
-
senderId,
|
|
586
|
-
role: 'agent',
|
|
587
|
-
parts: [{ kind: 'data', data: turnData }],
|
|
588
|
-
taskId: task.id,
|
|
589
|
-
});
|
|
590
|
-
const newTurnCount = turnCount + 1;
|
|
591
|
-
// ── Handle terminal actions (accept / reject / withdraw / decline): finalize immediately ──
|
|
592
|
-
if (isTerminalAction(query.action)) {
|
|
593
|
-
const allMessages = [...messages, { id: turnMessage.id, senderId: turnMessage.senderId, role: turnMessage.role, parts: turnMessage.parts, createdAt: turnMessage.createdAt }];
|
|
594
|
-
const history = turnsFromMessages(allMessages);
|
|
595
|
-
const nextSpeaker = currentSpeaker === 'source' ? 'candidate' : 'source';
|
|
596
|
-
const outcome = buildNegotiationOutcome(history, newTurnCount, query.action, meta.sourceUserId, meta.candidateUserId, nextSpeaker);
|
|
597
|
-
await negotiationDatabase.updateTaskState(task.id, 'completed');
|
|
598
|
-
await negotiationDatabase.createArtifact({
|
|
599
|
-
taskId: task.id,
|
|
600
|
-
name: 'negotiation-outcome',
|
|
601
|
-
parts: [{ kind: 'data', data: outcome }],
|
|
602
|
-
metadata: { hasOpportunity: outcome.hasOpportunity, turnCount: newTurnCount },
|
|
603
|
-
});
|
|
604
|
-
return success({
|
|
605
|
-
message: query.action === 'accept'
|
|
606
|
-
? 'Negotiation accepted. An opportunity has been created.'
|
|
607
|
-
: query.action === 'withdraw'
|
|
608
|
-
? 'Negotiation withdrawn.'
|
|
609
|
-
: query.action === 'decline'
|
|
610
|
-
? 'Negotiation declined.'
|
|
611
|
-
: 'Negotiation rejected.',
|
|
612
|
-
negotiationId: task.id,
|
|
613
|
-
action: query.action,
|
|
614
|
-
turnNumber: newTurnCount,
|
|
615
|
-
outcome,
|
|
616
|
-
});
|
|
617
|
-
}
|
|
618
|
-
// ── Handle counter/question: check if under max turns ──
|
|
619
|
-
const maxTurns = meta.maxTurns ?? 6; // Read from task metadata; fallback to system default
|
|
620
|
-
if (newTurnCount >= maxTurns) {
|
|
621
|
-
// Max turns reached — finalize with turn_cap
|
|
622
|
-
const allMessages = [...messages, { id: turnMessage.id, senderId: turnMessage.senderId, role: turnMessage.role, parts: turnMessage.parts, createdAt: turnMessage.createdAt }];
|
|
623
|
-
const history = turnsFromMessages(allMessages);
|
|
624
|
-
const nextSpeakerForCap = currentSpeaker === 'source' ? 'candidate' : 'source';
|
|
625
|
-
const outcome = buildNegotiationOutcome(history, newTurnCount, 'counter', meta.sourceUserId, meta.candidateUserId, nextSpeakerForCap);
|
|
626
|
-
await negotiationDatabase.updateTaskState(task.id, 'completed');
|
|
627
|
-
await negotiationDatabase.createArtifact({
|
|
628
|
-
taskId: task.id,
|
|
629
|
-
name: 'negotiation-outcome',
|
|
630
|
-
parts: [{ kind: 'data', data: outcome }],
|
|
631
|
-
metadata: { hasOpportunity: false, turnCount: newTurnCount },
|
|
632
|
-
});
|
|
633
|
-
return success({
|
|
634
|
-
message: 'Maximum turns reached. Negotiation finalized without opportunity.',
|
|
635
|
-
negotiationId: task.id,
|
|
636
|
-
action: query.action,
|
|
637
|
-
turnNumber: newTurnCount,
|
|
638
|
-
outcome,
|
|
639
|
-
});
|
|
640
|
-
}
|
|
641
|
-
// ── Counter/question under max turns: dispatch to counterparty's agent ──
|
|
642
|
-
const counterpartyUserId = isSource ? meta.candidateUserId : meta.sourceUserId;
|
|
643
|
-
const counterpartySpeaker = isSource ? 'candidate' : 'source';
|
|
644
|
-
const counterpartySeat = resolveSeat(counterpartyUserId, meta);
|
|
645
|
-
// Build the current turn history for dispatcher payload
|
|
646
|
-
const allMessagesWithTurn = [...messages, { id: turnMessage.id, senderId: turnMessage.senderId, role: turnMessage.role, parts: turnMessage.parts, createdAt: turnMessage.createdAt }];
|
|
647
|
-
const historyForDispatch = turnsFromMessages(allMessagesWithTurn);
|
|
648
|
-
const isFinalTurn = newTurnCount + 1 >= maxTurns;
|
|
649
|
-
const ownUserCtx = { id: counterpartyUserId, intents: [], profile: {} };
|
|
650
|
-
const otherUserCtx = { id: context.userId, intents: [], profile: {} };
|
|
651
|
-
const seedAssessment = { reasoning: 'Continued negotiation', valencyRole: 'peer' };
|
|
652
|
-
const dispatchPayload = {
|
|
653
|
-
negotiationId: task.id,
|
|
654
|
-
ownUser: ownUserCtx,
|
|
655
|
-
otherUser: otherUserCtx,
|
|
656
|
-
indexContext: { networkId: '' },
|
|
657
|
-
seedAssessment,
|
|
658
|
-
history: historyForDispatch,
|
|
659
|
-
isFinalTurn,
|
|
660
|
-
isDiscoverer: false,
|
|
661
|
-
seat: counterpartySeat,
|
|
662
|
-
protocolVersion,
|
|
663
|
-
allowedActions: [...allowedActionsFor(protocolVersion, counterpartySeat, isFinalTurn)],
|
|
664
|
-
};
|
|
665
|
-
const scope = { action: 'negotiation.respond', scopeType: 'negotiation', scopeId: task.id };
|
|
666
|
-
const timeoutMs = AMBIENT_PARK_WINDOW_MS;
|
|
667
|
-
const dispatchResult = await deps.agentDispatcher?.dispatch(counterpartyUserId, scope, dispatchPayload, { timeoutMs });
|
|
668
|
-
if (dispatchResult?.handled === false && dispatchResult.reason === 'waiting') {
|
|
669
|
-
// Counterparty's agent acknowledged — yield and wait
|
|
670
|
-
await negotiationDatabase.updateTaskState(task.id, 'waiting_for_agent');
|
|
671
|
-
if (deps.negotiationTimeoutQueue) {
|
|
672
|
-
await deps.negotiationTimeoutQueue.enqueueTimeout(task.id, newTurnCount, timeoutMs);
|
|
673
|
-
}
|
|
674
|
-
return success({
|
|
675
|
-
message: `${query.action === 'question' ? 'Question' : query.action === 'propose' ? 'Proposal' : query.action === 'outreach' ? 'Outreach' : 'Counter-proposal'} submitted. Waiting for counterparty response.`,
|
|
676
|
-
negotiationId: task.id,
|
|
677
|
-
action: query.action,
|
|
678
|
-
turnNumber: newTurnCount,
|
|
679
|
-
waitingForAgent: true,
|
|
680
|
-
});
|
|
681
|
-
}
|
|
682
|
-
let aiTurn;
|
|
683
|
-
if (dispatchResult?.handled === true) {
|
|
684
|
-
// Dispatcher returned an agent turn directly
|
|
685
|
-
aiTurn = dispatchResult.turn;
|
|
686
|
-
}
|
|
687
|
-
else {
|
|
688
|
-
// No agent or timeout — run the system AI agent inline.
|
|
689
|
-
// The agent honors a per-turn LLM timeout (AbortSignal), so invoke
|
|
690
|
-
// can reject. Mirror the graph turnNode's reject-shaped fallback so
|
|
691
|
-
// a timed-out or failed call degrades gracefully instead of leaving
|
|
692
|
-
// the task pinned in `working` while the outer catch returns a bare
|
|
693
|
-
// error to the user.
|
|
694
|
-
await negotiationDatabase.updateTaskState(task.id, 'working');
|
|
695
|
-
const agent = new IndexNegotiator();
|
|
696
|
-
try {
|
|
697
|
-
aiTurn = await agent.invoke({
|
|
698
|
-
ownUser: ownUserCtx,
|
|
699
|
-
otherUser: otherUserCtx,
|
|
700
|
-
indexContext: { networkId: '' },
|
|
701
|
-
seedAssessment,
|
|
702
|
-
history: historyForDispatch,
|
|
703
|
-
isFinalTurn,
|
|
704
|
-
seat: counterpartySeat,
|
|
705
|
-
protocolVersion,
|
|
706
|
-
});
|
|
707
|
-
}
|
|
708
|
-
catch (err) {
|
|
709
|
-
const errMsg = err instanceof Error ? err.message : String(err);
|
|
710
|
-
const errName = err?.name ?? '';
|
|
711
|
-
const isTimeout = errName === 'TimeoutError' || /timeout|abort/i.test(errMsg);
|
|
712
|
-
// Log the raw error for ops, but keep the persisted/returned
|
|
713
|
-
// reasoning generic — this string round-trips back to the caller
|
|
714
|
-
// via counterpartyResponse.reasoning and ends up in the negotiation
|
|
715
|
-
// history visible through get_negotiation, so we don't want raw
|
|
716
|
-
// provider messages (URLs, request IDs, internal stack hints) on
|
|
717
|
-
// the wire.
|
|
718
|
-
logger.warn('System negotiator inline invoke failed; treating as reject', {
|
|
719
|
-
taskId: task.id,
|
|
720
|
-
isTimeout,
|
|
721
|
-
error: errMsg,
|
|
722
|
-
});
|
|
723
|
-
aiTurn = {
|
|
724
|
-
action: rejectActionFor(protocolVersion, counterpartySeat),
|
|
725
|
-
assessment: {
|
|
726
|
-
reasoning: isTimeout
|
|
727
|
-
? 'Negotiator response timed out.'
|
|
728
|
-
: 'Negotiator failed to produce a response.',
|
|
729
|
-
suggestedRoles: { ownUser: 'peer', otherUser: 'peer' },
|
|
730
|
-
},
|
|
731
|
-
};
|
|
732
|
-
}
|
|
733
|
-
}
|
|
734
|
-
// Persist the counterparty's turn (from dispatcher or inline AI)
|
|
735
|
-
const aiSenderId = `agent:${counterpartyUserId}`;
|
|
736
|
-
await negotiationDatabase.createMessage({
|
|
737
|
-
conversationId: task.conversationId,
|
|
738
|
-
senderId: aiSenderId,
|
|
739
|
-
role: 'agent',
|
|
740
|
-
parts: [{ kind: 'data', data: aiTurn }],
|
|
741
|
-
taskId: task.id,
|
|
742
|
-
});
|
|
743
|
-
const finalTurnCount = newTurnCount + 1;
|
|
744
|
-
// Evaluate response
|
|
745
|
-
if (isTerminalAction(aiTurn.action)) {
|
|
746
|
-
const fullHistory = [...historyForDispatch, aiTurn];
|
|
747
|
-
const outcome = buildNegotiationOutcome(fullHistory, finalTurnCount, aiTurn.action, meta.sourceUserId, meta.candidateUserId, counterpartySpeaker === 'source' ? 'candidate' : 'source');
|
|
748
|
-
await negotiationDatabase.updateTaskState(task.id, 'completed');
|
|
749
|
-
await negotiationDatabase.createArtifact({
|
|
750
|
-
taskId: task.id,
|
|
751
|
-
name: 'negotiation-outcome',
|
|
752
|
-
parts: [{ kind: 'data', data: outcome }],
|
|
753
|
-
metadata: { hasOpportunity: outcome.hasOpportunity, turnCount: finalTurnCount },
|
|
754
|
-
});
|
|
755
|
-
return success({
|
|
756
|
-
message: `${query.action === 'question' ? 'Question' : query.action === 'propose' ? 'Proposal' : 'Counter'} submitted. Counterparty responded with ${aiTurn.action}.`,
|
|
757
|
-
negotiationId: task.id,
|
|
758
|
-
action: query.action,
|
|
759
|
-
turnNumber: newTurnCount,
|
|
760
|
-
counterpartyResponse: { action: aiTurn.action, reasoning: aiTurn.assessment.reasoning, message: aiTurn.message ?? null },
|
|
761
|
-
outcome,
|
|
762
|
-
});
|
|
763
|
-
}
|
|
764
|
-
// Counterparty countered/questioned — check if max turns reached
|
|
765
|
-
if (finalTurnCount >= maxTurns) {
|
|
766
|
-
const fullHistory = [...historyForDispatch, aiTurn];
|
|
767
|
-
const outcome = buildNegotiationOutcome(fullHistory, finalTurnCount, 'counter', meta.sourceUserId, meta.candidateUserId, counterpartySpeaker === 'source' ? 'candidate' : 'source');
|
|
768
|
-
await negotiationDatabase.updateTaskState(task.id, 'completed');
|
|
769
|
-
await negotiationDatabase.createArtifact({
|
|
770
|
-
taskId: task.id,
|
|
771
|
-
name: 'negotiation-outcome',
|
|
772
|
-
parts: [{ kind: 'data', data: outcome }],
|
|
773
|
-
metadata: { hasOpportunity: false, turnCount: finalTurnCount },
|
|
774
|
-
});
|
|
775
|
-
return success({
|
|
776
|
-
message: 'Counterparty responded but max turns reached. Negotiation finalized.',
|
|
777
|
-
negotiationId: task.id,
|
|
778
|
-
action: query.action,
|
|
779
|
-
turnNumber: newTurnCount,
|
|
780
|
-
counterpartyResponse: { action: aiTurn.action, reasoning: aiTurn.assessment.reasoning, message: aiTurn.message ?? null },
|
|
781
|
-
outcome,
|
|
782
|
-
});
|
|
783
|
-
}
|
|
784
|
-
// Counterparty countered/questioned, now user's turn again — dispatch to user's agent
|
|
785
|
-
const userDispatchPayload = {
|
|
786
|
-
negotiationId: task.id,
|
|
787
|
-
ownUser: { id: context.userId, intents: [], profile: {} },
|
|
788
|
-
otherUser: { id: counterpartyUserId, intents: [], profile: {} },
|
|
789
|
-
indexContext: { networkId: '' },
|
|
790
|
-
seedAssessment,
|
|
791
|
-
history: [...historyForDispatch, aiTurn],
|
|
792
|
-
isFinalTurn: finalTurnCount + 1 >= maxTurns,
|
|
793
|
-
isDiscoverer: true,
|
|
794
|
-
seat,
|
|
795
|
-
protocolVersion,
|
|
796
|
-
allowedActions: [...allowedActionsFor(protocolVersion, seat, finalTurnCount + 1 >= maxTurns)],
|
|
797
|
-
};
|
|
798
|
-
const userDispatchResult = await deps.agentDispatcher?.dispatch(context.userId, scope, userDispatchPayload, { timeoutMs });
|
|
799
|
-
if (!userDispatchResult || (userDispatchResult.handled === false && userDispatchResult.reason === 'no_agent')) {
|
|
800
|
-
// No agent for user — set back to waiting_for_agent so they can use respond_to_negotiation
|
|
801
|
-
await negotiationDatabase.updateTaskState(task.id, 'waiting_for_agent');
|
|
802
|
-
if (deps.negotiationTimeoutQueue) {
|
|
803
|
-
await deps.negotiationTimeoutQueue.enqueueTimeout(task.id, finalTurnCount, timeoutMs);
|
|
804
|
-
}
|
|
805
|
-
return success({
|
|
806
|
-
message: `${query.action === 'question' ? 'Question' : 'Counter'} submitted. Counterparty responded. Your turn to respond.`,
|
|
807
|
-
negotiationId: task.id,
|
|
808
|
-
action: query.action,
|
|
809
|
-
turnNumber: newTurnCount,
|
|
810
|
-
counterpartyResponse: { action: aiTurn.action, reasoning: aiTurn.assessment.reasoning, message: aiTurn.message ?? null },
|
|
811
|
-
waitingForAgent: true,
|
|
812
|
-
});
|
|
813
|
-
}
|
|
814
|
-
if (userDispatchResult.handled === false && userDispatchResult.reason === 'waiting') {
|
|
815
|
-
// User's agent acknowledged — yield and wait
|
|
816
|
-
await negotiationDatabase.updateTaskState(task.id, 'waiting_for_agent');
|
|
817
|
-
if (deps.negotiationTimeoutQueue) {
|
|
818
|
-
await deps.negotiationTimeoutQueue.enqueueTimeout(task.id, finalTurnCount, timeoutMs);
|
|
819
|
-
}
|
|
820
|
-
return success({
|
|
821
|
-
message: `${query.action === 'question' ? 'Question' : 'Counter'} submitted. Counterparty countered back. Waiting for your agent's response.`,
|
|
822
|
-
negotiationId: task.id,
|
|
823
|
-
action: query.action,
|
|
824
|
-
turnNumber: newTurnCount,
|
|
825
|
-
counterpartyResponse: { action: aiTurn.action, reasoning: aiTurn.assessment.reasoning, message: aiTurn.message ?? null },
|
|
826
|
-
waitingForAgent: true,
|
|
827
|
-
});
|
|
828
|
-
}
|
|
829
|
-
if (userDispatchResult.handled === true) {
|
|
830
|
-
// User's agent returned a turn directly — persist, evaluate, and continue
|
|
831
|
-
const userAgentTurn = userDispatchResult.turn;
|
|
832
|
-
const userAgentSenderId = `agent:${context.userId}`;
|
|
833
|
-
await negotiationDatabase.createMessage({
|
|
834
|
-
conversationId: task.conversationId,
|
|
835
|
-
senderId: userAgentSenderId,
|
|
836
|
-
role: 'agent',
|
|
837
|
-
parts: [{ kind: 'data', data: userAgentTurn }],
|
|
838
|
-
taskId: task.id,
|
|
839
|
-
});
|
|
840
|
-
const userTurnCount = finalTurnCount + 1;
|
|
841
|
-
if (isTerminalAction(userAgentTurn.action)) {
|
|
842
|
-
const fullHistory = [...historyForDispatch, aiTurn, userAgentTurn];
|
|
843
|
-
const userSpeaker = isSource ? 'source' : 'candidate';
|
|
844
|
-
const outcome = buildNegotiationOutcome(fullHistory, userTurnCount, userAgentTurn.action, meta.sourceUserId, meta.candidateUserId, userSpeaker === 'source' ? 'candidate' : 'source');
|
|
845
|
-
await negotiationDatabase.updateTaskState(task.id, 'completed');
|
|
846
|
-
await negotiationDatabase.createArtifact({
|
|
847
|
-
taskId: task.id,
|
|
848
|
-
name: 'negotiation-outcome',
|
|
849
|
-
parts: [{ kind: 'data', data: outcome }],
|
|
850
|
-
metadata: { hasOpportunity: outcome.hasOpportunity, turnCount: userTurnCount },
|
|
851
|
-
});
|
|
852
|
-
return success({
|
|
853
|
-
message: `Your agent ${userAgentTurn.action}ed the counterparty's response.`,
|
|
854
|
-
negotiationId: task.id,
|
|
855
|
-
action: query.action,
|
|
856
|
-
turnNumber: newTurnCount,
|
|
857
|
-
counterpartyResponse: { action: aiTurn.action, reasoning: aiTurn.assessment.reasoning, message: aiTurn.message ?? null },
|
|
858
|
-
outcome,
|
|
859
|
-
});
|
|
860
|
-
}
|
|
861
|
-
if (userTurnCount >= maxTurns) {
|
|
862
|
-
const fullHistory = [...historyForDispatch, aiTurn, userAgentTurn];
|
|
863
|
-
const outcome = buildNegotiationOutcome(fullHistory, userTurnCount, 'counter', meta.sourceUserId, meta.candidateUserId, isSource ? 'candidate' : 'source');
|
|
864
|
-
await negotiationDatabase.updateTaskState(task.id, 'completed');
|
|
865
|
-
await negotiationDatabase.createArtifact({
|
|
866
|
-
taskId: task.id,
|
|
867
|
-
name: 'negotiation-outcome',
|
|
868
|
-
parts: [{ kind: 'data', data: outcome }],
|
|
869
|
-
metadata: { hasOpportunity: false, turnCount: userTurnCount },
|
|
870
|
-
});
|
|
871
|
-
return success({
|
|
872
|
-
message: 'Your agent responded but max turns reached. Negotiation finalized.',
|
|
873
|
-
negotiationId: task.id,
|
|
874
|
-
action: query.action,
|
|
875
|
-
turnNumber: newTurnCount,
|
|
876
|
-
counterpartyResponse: { action: aiTurn.action, reasoning: aiTurn.assessment.reasoning, message: aiTurn.message ?? null },
|
|
877
|
-
outcome,
|
|
878
|
-
});
|
|
879
|
-
}
|
|
880
|
-
// User's agent countered/questioned — arm timeout for counterparty's next turn
|
|
881
|
-
await negotiationDatabase.updateTaskState(task.id, 'waiting_for_agent');
|
|
882
|
-
if (deps.negotiationTimeoutQueue) {
|
|
883
|
-
await deps.negotiationTimeoutQueue.enqueueTimeout(task.id, userTurnCount, timeoutMs);
|
|
884
|
-
}
|
|
885
|
-
return success({
|
|
886
|
-
message: `Your agent responded with ${userAgentTurn.action}. Waiting for counterparty.`,
|
|
887
|
-
negotiationId: task.id,
|
|
888
|
-
action: query.action,
|
|
889
|
-
turnNumber: newTurnCount,
|
|
890
|
-
counterpartyResponse: { action: aiTurn.action, reasoning: aiTurn.assessment.reasoning, message: aiTurn.message ?? null },
|
|
891
|
-
waitingForAgent: true,
|
|
892
|
-
});
|
|
893
|
-
}
|
|
894
|
-
// No agent / timeout — set back to working so graph can continue
|
|
895
|
-
await negotiationDatabase.updateTaskState(task.id, 'working');
|
|
896
|
-
return success({
|
|
897
|
-
message: `${query.action === 'question' ? 'Question' : 'Counter'} submitted. Counterparty countered back. Negotiation continues.`,
|
|
898
|
-
negotiationId: task.id,
|
|
899
|
-
action: query.action,
|
|
900
|
-
turnNumber: newTurnCount,
|
|
901
|
-
counterpartyResponse: { action: aiTurn.action, reasoning: aiTurn.assessment.reasoning, message: aiTurn.message ?? null },
|
|
902
|
-
});
|
|
903
|
-
}
|
|
904
|
-
catch (err) {
|
|
905
|
-
logger.error('Failed to respond to negotiation', { err });
|
|
906
|
-
return error('Failed to respond to negotiation. Please try again.');
|
|
907
|
-
}
|
|
908
|
-
},
|
|
909
|
-
});
|
|
910
|
-
return [list_negotiations, get_negotiation, respond_to_negotiation];
|
|
911
|
-
}
|
|
912
|
-
/**
|
|
913
|
-
* Build a NegotiationOutcome from the full turn history.
|
|
914
|
-
* Mirrors the logic in the graph's finalizeNode for consistency.
|
|
915
|
-
*
|
|
916
|
-
* @param history - All negotiation turns
|
|
917
|
-
* @param turnCount - Total number of turns
|
|
918
|
-
* @param lastAction - The last turn's action (accept/reject/counter)
|
|
919
|
-
* @param sourceUserId - Source user ID
|
|
920
|
-
* @param candidateUserId - Candidate user ID
|
|
921
|
-
* @param currentSpeaker - Who would speak next (the person after the accepter/rejector)
|
|
922
|
-
*/
|
|
923
|
-
function buildNegotiationOutcome(history, turnCount, lastAction, sourceUserId, candidateUserId, currentSpeaker) {
|
|
924
|
-
const hasOpportunity = lastAction === 'accept';
|
|
925
|
-
// Non-terminal last action at finalization means the turn cap was hit.
|
|
926
|
-
const atCap = !isTerminalAction(lastAction);
|
|
927
|
-
let agreedRoles = [];
|
|
928
|
-
if (hasOpportunity && history.length >= 2) {
|
|
929
|
-
const acceptTurn = history[history.length - 1];
|
|
930
|
-
const precedingTurn = history[history.length - 2];
|
|
931
|
-
const accepterIsSource = currentSpeaker === 'candidate';
|
|
932
|
-
const [sourceRole, candidateRole] = accepterIsSource
|
|
933
|
-
? [acceptTurn.assessment.suggestedRoles.ownUser, precedingTurn.assessment.suggestedRoles.ownUser]
|
|
934
|
-
: [precedingTurn.assessment.suggestedRoles.ownUser, acceptTurn.assessment.suggestedRoles.ownUser];
|
|
935
|
-
agreedRoles = [
|
|
936
|
-
{ userId: sourceUserId, role: sourceRole },
|
|
937
|
-
{ userId: candidateUserId, role: candidateRole },
|
|
938
|
-
];
|
|
939
|
-
}
|
|
940
|
-
return {
|
|
941
|
-
hasOpportunity,
|
|
942
|
-
agreedRoles,
|
|
943
|
-
reasoning: history[history.length - 1]?.assessment.reasoning ?? '',
|
|
944
|
-
turnCount,
|
|
945
|
-
...(atCap && { reason: 'turn_cap' }),
|
|
946
|
-
};
|
|
947
|
-
}
|
|
948
|
-
//# sourceMappingURL=negotiation.tools.js.map
|
|
5
|
+
export * from "./application/negotiation.tools.js";
|