@voxket-ai/voxket-live 1.1.50 ā 1.1.51
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.cjs +8 -1
- package/dist/index.js +4875 -4855
- package/package.json +1 -1
package/dist/index.cjs
CHANGED
|
@@ -198,4 +198,11 @@ const response = await participant.performRpc({
|
|
|
198
198
|
})
|
|
199
199
|
});
|
|
200
200
|
|
|
201
|
-
console.log('User response:', response);`})]})]})}const qV={async checkAvailableRpcs(e){const t=e.getRegisteredRpcMethods();return console.log("š Agent: Available RPC methods:",t),t},async triggerAssignment(e,t){const n={title:"Complete Q4 Sales Analysis Report",description:"Please analyze the Q4 sales data and create a comprehensive report with insights, trends, and recommendations for the upcoming quarter. Include visualizations and executive summary.",estimated_time_of_completion:"2-3 hours"};try{console.log("š¤ Agent: Triggering give_assignment RPC with data:",n);const i=await e.localParticipant.performRpc(t,"give_assignment",JSON.stringify(n),{responseTimeout:12e4}),r=JSON.parse(i);return console.log("ā
Agent: Received user response:",r),await this.processAssignmentResponse(r),r}catch(i){throw console.error("ā Agent: RPC failed:",i),i}},async processAssignmentResponse(e){console.log("š§ Agent: Processing assignment response...");const t=e.status,n=e.assignmentId,i=e.timeSpent;return t==="accepted"?(console.log("š Agent: User accepted the assignment!"),console.log(`ļæ½ Assignment ID: ${n}`),console.log(`ā±ļø Time to respond: ${i}ms`),console.log("š¬ Agent: Sending follow-up:","Great! I've recorded that you've accepted the assignment. You'll receive the detailed requirements and access to the data shortly. Let me know if you need any clarification!")):t==="declined"?(console.log("ā Agent: User declined the assignment"),console.log("š¬ Agent: Sending follow-up:","No problem! Is there anything specific about this assignment that doesn't work for you? I can suggest alternatives or modify the requirements.")):t==="completed"&&(console.log("ā
Agent: User completed the assignment"),console.log("š¬ Agent: Sending follow-up:","Excellent work! Could you please share the completed report? I'm excited to review your analysis and insights.")),{status:t,assignmentId:n,timeSpent:i,processed:!0,followupAction:t==="accepted"?"send_requirements":t==="declined"?"offer_alternatives":"request_deliverables"}},getAssignmentExamples(){return{marketing:{title:"Create Social Media Campaign",description:"Design and plan a social media campaign for our new product launch. Include content calendar, post designs, and engagement strategy.",estimated_time_of_completion:"4-5 hours"},technical:{title:"API Integration Documentation",description:"Create comprehensive documentation for our new API endpoints, including examples, error codes, and best practices for developers.",estimated_time_of_completion:"6-8 hours"},research:{title:"Market Research Analysis",description:"Research and analyze competitor pricing strategies in our target market. Provide recommendations for our pricing model.",estimated_time_of_completion:"3-4 hours"},quick:{title:"Customer Feedback Summary",description:"Review this week's customer feedback and create a summary of key themes and actionable insights.",estimated_time_of_completion:"30-45 minutes"}}}}
|
|
201
|
+
console.log('User response:', response);`})]})]})}const qV={async checkAvailableRpcs(e){const t=e.getRegisteredRpcMethods();return console.log("š Agent: Available RPC methods:",t),t},async triggerAssignment(e,t){const n={title:"Complete Q4 Sales Analysis Report",description:"Please analyze the Q4 sales data and create a comprehensive report with insights, trends, and recommendations for the upcoming quarter. Include visualizations and executive summary.",estimated_time_of_completion:"2-3 hours"};try{console.log("š¤ Agent: Triggering give_assignment RPC with data:",n);const i=await e.localParticipant.performRpc(t,"give_assignment",JSON.stringify(n),{responseTimeout:12e4}),r=JSON.parse(i);return console.log("ā
Agent: Received user response:",r),await this.processAssignmentResponse(r),r}catch(i){throw console.error("ā Agent: RPC failed:",i),i}},async processAssignmentResponse(e){console.log("š§ Agent: Processing assignment response...");const t=e.status,n=e.assignmentId,i=e.timeSpent;return t==="accepted"?(console.log("š Agent: User accepted the assignment!"),console.log(`ļæ½ Assignment ID: ${n}`),console.log(`ā±ļø Time to respond: ${i}ms`),console.log("š¬ Agent: Sending follow-up:","Great! I've recorded that you've accepted the assignment. You'll receive the detailed requirements and access to the data shortly. Let me know if you need any clarification!")):t==="declined"?(console.log("ā Agent: User declined the assignment"),console.log("š¬ Agent: Sending follow-up:","No problem! Is there anything specific about this assignment that doesn't work for you? I can suggest alternatives or modify the requirements.")):t==="completed"&&(console.log("ā
Agent: User completed the assignment"),console.log("š¬ Agent: Sending follow-up:","Excellent work! Could you please share the completed report? I'm excited to review your analysis and insights.")),{status:t,assignmentId:n,timeSpent:i,processed:!0,followupAction:t==="accepted"?"send_requirements":t==="declined"?"offer_alternatives":"request_deliverables"}},getAssignmentExamples(){return{marketing:{title:"Create Social Media Campaign",description:"Design and plan a social media campaign for our new product launch. Include content calendar, post designs, and engagement strategy.",estimated_time_of_completion:"4-5 hours"},technical:{title:"API Integration Documentation",description:"Create comprehensive documentation for our new API endpoints, including examples, error codes, and best practices for developers.",estimated_time_of_completion:"6-8 hours"},research:{title:"Market Research Analysis",description:"Research and analyze competitor pricing strategies in our target market. Provide recommendations for our pricing model.",estimated_time_of_completion:"3-4 hours"},quick:{title:"Customer Feedback Summary",description:"Review this week's customer feedback and create a summary of key themes and actionable insights.",estimated_time_of_completion:"30-45 minutes"}}}};typeof document<"u"&&setTimeout(()=>{const e=document.createElement("div");e.className="flex",e.style.cssText="position:absolute;visibility:hidden;pointer-events:none;",document.body.appendChild(e);const t=window.getComputedStyle(e).display==="flex";document.body.removeChild(e),t?console.log("ā
Voxket SDK: CSS styles loaded successfully"):console.warn(`%cā ļø Voxket SDK: CSS styles not loaded!
|
|
202
|
+
|
|
203
|
+
%cThe widget will not display correctly.
|
|
204
|
+
Please add this import to your app:
|
|
205
|
+
|
|
206
|
+
%cimport '@voxket-ai/voxket-live/style.css';
|
|
207
|
+
|
|
208
|
+
%cSee: https://github.com/voxket-ai/voxket-web-sdk#installation`,"color: #f59e0b; font-size: 14px; font-weight: bold;","color: #fbbf24; font-size: 12px;","color: #22c55e; font-size: 12px; font-family: monospace; background: #1e293b; padding: 4px 8px; border-radius: 4px;","color: #3b82f6; font-size: 12px;")},100);const YV=e=>typeof window>"u"?null:D.createElement(kf,{children:D.createElement(Pa,e)});exports.AgentManager=Sw;exports.AssignmentView=Bw;exports.ChatManager=gw;exports.CommonPopupTrigger=hw;exports.CompoundProvider=Mw;exports.ConnectionManager=yw;exports.InteractiveComponent=uo;exports.MediaManager=bw;exports.PluginManager=pw;exports.RpcExamples=WV;exports.RpcManager=mw;exports.SessionContainer=Ow;exports.SessionContent=Tf;exports.SessionControls=Nw;exports.SessionFooter=Af;exports.SessionHeader=Ef;exports.SessionLogViewer=vV;exports.SessionMetricsComponent=xV;exports.SessionTimer=ho;exports.Slot=Na;exports.StreamHandlerManager=vw;exports.ThemeProvider=AV;exports.UIRenderer=kw;exports.VideoControls=QV;exports.VideoGrid=HV;exports.VideoTile=Oa;exports.VideoView=WS;exports.VoxketClient=Mo;exports.VoxketErrorBoundary=kf;exports.VoxketEventEmitter=Sf;exports.VoxketProvider=Ma;exports.VoxketSDK=Mo;exports.VoxketSessionComponent=Ow;exports.agentRpcExample=qV;exports.analyticsPlugin=lV;exports.chatModalityPlugin=_V;exports.createCustomTheme=IV;exports.createModalityPlugin=wf;exports.createPlugin=cV;exports.createSessionFixture=wc;exports.darkTheme=Ld;exports.debugPlugin=uV;exports.default=YV;exports.defaultTheme=fr;exports.enterpriseTheme=Bd;exports.flattenTheme=Lw;exports.formatSessionTimer=yk;exports.getChatCapabilities=gk;exports.getSessionTimer=Cc;exports.getVideoCapabilities=mk;exports.getVoiceCapabilities=bk;exports.isCapabilityEnabled=_O;exports.metricsPlugin=dV;exports.useComponentTheme=RV;exports.useCompoundContext=Po;exports.useSessionLogging=fw;exports.useTheme=Dw;exports.useVoxket=si;exports.useVoxketCamera=Tw;exports.useVoxketChat=Gc;exports.useVoxketChatInput=SV;exports.useVoxketConnection=Cf;exports.useVoxketMetrics=Cw;exports.useVoxketMicrophone=Ew;exports.useVoxketParticipants=Iw;exports.useVoxketScreenShare=Aw;exports.useVoxketSession=wr;exports.useVoxketVideo=kV;exports.voiceModalityPlugin=MV;exports.withCompoundComponent=Pw;
|