forkit-connect 0.1.8 → 0.1.9

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/cli.js CHANGED
@@ -1468,6 +1468,7 @@ function printConnectStatusOverview(status) {
1468
1468
  paused_session_count: status.paused_session_count,
1469
1469
  revoked_session_count: status.revoked_session_count,
1470
1470
  credential_reconnect_needed: status.credential_reconnect_needed,
1471
+ draft_first_count: status.draft_first_count,
1471
1472
  ready_to_connect_count: status.ready_to_connect_count,
1472
1473
  needs_confirmation_count: status.needs_confirmation_count,
1473
1474
  connected_count: status.connected_count,
@@ -1478,12 +1479,13 @@ function printConnectStatusOverview(status) {
1478
1479
  }, null, 2));
1479
1480
  }
1480
1481
  function printPublicStatusOverview(status) {
1482
+ const otherReadyCount = Math.max(0, status.ready_to_connect_count - status.draft_first_count);
1481
1483
  console.log('[forkit-connect] Status');
1482
1484
  console.log(`- device=${status.device_paired ? 'paired' : 'approval pending'}`);
1483
1485
  console.log(`- scope=${status.workspace_id && status.project_id ? `${status.workspace_id} / ${status.project_id}` : 'not selected'}`);
1484
1486
  console.log(`- daemon=${status.daemon_status}`);
1485
1487
  console.log(`- local inventory=models ${status.models_discovered} · agents ${status.agents_discovered} · runtimes ${status.runtimes_discovered}`);
1486
- console.log(`- review queue=ready ${status.ready_to_connect_count} · needs review ${status.needs_confirmation_count}`);
1488
+ console.log(`- review queue=draft first ${status.draft_first_count} · ready ${otherReadyCount} · needs review ${status.needs_confirmation_count}`);
1487
1489
  console.log(`- connected records=${status.connected_count}`);
1488
1490
  console.log(`- pending runtime sync=${status.c2_sync_pending}`);
1489
1491
  console.log(`- privacy=${status.privacy_mode}`);
@@ -1752,8 +1754,11 @@ async function run() {
1752
1754
  preferSnapshot: true,
1753
1755
  refreshInBackground: false,
1754
1756
  });
1757
+ const draftFirstCount = inbox.groups.ready_to_connect.filter((item) => (item.item_type === 'model'
1758
+ && String(item.details_received_automatically.registration_flow_state || '').trim() === 'private_draft_required')).length;
1755
1759
  return {
1756
1760
  ...overview,
1761
+ draft_first_count: draftFirstCount,
1757
1762
  ready_to_connect_count: inbox.summary.ready_to_connect_count,
1758
1763
  needs_confirmation_count: inbox.summary.needs_confirmation_count,
1759
1764
  connected_count: inbox.summary.connected_count,
@@ -2075,6 +2080,7 @@ async function run() {
2075
2080
  ? 'Local workspace/project scope is cached on this device, but account login is required before governed actions can continue.'
2076
2081
  : 'Account login is required before governed workspace/project actions can continue.',
2077
2082
  daemon_status: overview.daemon_status,
2083
+ draft_first_count: overview.draft_first_count,
2078
2084
  ready_to_connect_count: overview.ready_to_connect_count,
2079
2085
  needs_confirmation_count: overview.needs_confirmation_count,
2080
2086
  connected_count: overview.connected_count,
@@ -2118,6 +2124,7 @@ async function run() {
2118
2124
  {
2119
2125
  title: 'Queue',
2120
2126
  lines: [
2127
+ shellLine('Draft-first review', payload.draft_first_count),
2121
2128
  shellLine('Ready to connect', payload.ready_to_connect_count),
2122
2129
  shellLine('Needs confirmation', payload.needs_confirmation_count),
2123
2130
  shellLine('Connected', payload.connected_count),
package/dist/launcher.js CHANGED
@@ -912,6 +912,9 @@ function buildDiscovery(service) {
912
912
  const modelItems = items.filter((item) => item.kind === 'model');
913
913
  const agentItems = items.filter((item) => item.kind === 'agent');
914
914
  const runtimeItems = items.filter((item) => item.kind === 'runtime');
915
+ const draftFirstCount = inbox.groups.ready_to_connect.filter((item) => (item.item_type === 'model'
916
+ && String(item.details_received_automatically.registration_flow_state || '').trim() === 'private_draft_required')).length;
917
+ const otherReadyCount = Math.max(0, inbox.summary.ready_to_connect_count - draftFirstCount);
915
918
  return {
916
919
  ok: true,
917
920
  generatedAt: new Date().toISOString(),
@@ -926,7 +929,7 @@ function buildDiscovery(service) {
926
929
  localDetection: state.detected_runtimes.length > 0 || state.detected_models.length > 0 ? 'active' : 'attention',
927
930
  metadataExtraction: state.detected_models.length > 0 ? 'active' : 'attention',
928
931
  duplicateMatching: inbox.existing_passport_match_candidates.length > 0 || state.model_bindings.length > 0 ? 'active' : 'attention',
929
- passportReadiness: `${inbox.summary.ready_to_connect_count} ready · ${inbox.summary.needs_confirmation_count} review · ${inbox.summary.connected_count} linked`,
932
+ passportReadiness: `${draftFirstCount} draft-first · ${otherReadyCount} ready · ${inbox.summary.needs_confirmation_count} review · ${inbox.summary.connected_count} linked`,
930
933
  },
931
934
  groups: {
932
935
  ready_to_connect: inbox.groups.ready_to_connect.length,
@@ -253,6 +253,7 @@ export interface ConnectStatusOverview {
253
253
  paused_session_count: number;
254
254
  revoked_session_count: number;
255
255
  credential_reconnect_needed: boolean;
256
+ draft_first_count: number;
256
257
  ready_to_connect_count: number;
257
258
  needs_confirmation_count: number;
258
259
  connected_count: number;
@@ -4725,6 +4725,11 @@ class ConnectV1Service {
4725
4725
  const state = this.stateStore.readState();
4726
4726
  const includeInbox = options?.includeInbox !== false;
4727
4727
  const inbox = includeInbox ? this.buildSmartRegistrationInbox() : null;
4728
+ const draftFirstCount = inbox
4729
+ ? inbox.groups.ready_to_connect.filter((item) => (item.item_type === 'model'
4730
+ && String(item.details_received_automatically.registration_flow_state || '').trim() === 'private_draft_required')).length
4731
+ : state.detected_models.filter((item) => (item.status !== 'ignored'
4732
+ && String((item.metadata && typeof item.metadata === 'object' ? item.metadata : {}).tracking_status || '').trim() === 'private_draft_required')).length;
4728
4733
  const sessionSummary = this.getC2SessionSummary();
4729
4734
  const binding = this.getEffectiveBindingState(state);
4730
4735
  const bindingReconnectRequired = this.bindingRequiresReconnect(state);
@@ -4744,6 +4749,7 @@ class ConnectV1Service {
4744
4749
  paused_session_count: sessionSummary.paused_session_count,
4745
4750
  revoked_session_count: sessionSummary.revoked_session_count,
4746
4751
  credential_reconnect_needed: bindingReconnectRequired || sessionSummary.credential_reconnect_needed,
4752
+ draft_first_count: draftFirstCount,
4747
4753
  ready_to_connect_count: inbox?.summary.ready_to_connect_count ?? discoveredModels,
4748
4754
  needs_confirmation_count: inbox?.summary.needs_confirmation_count ?? 0,
4749
4755
  connected_count: inbox?.summary.connected_count ?? connectedCount,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "forkit-connect",
3
- "version": "0.1.8",
3
+ "version": "0.1.9",
4
4
  "description": "Forkit Connect Local Engine - The Global AI Governance Fabric",
5
5
  "license": "MIT",
6
6
  "main": "dist/index.js",