@tscircuit/core 0.0.533 → 0.0.535

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/dist/index.js +178 -213
  2. package/package.json +10 -3
package/dist/index.js CHANGED
@@ -5384,7 +5384,6 @@ var Trace2 = class extends PrimitiveComponent2 {
5384
5384
  }
5385
5385
  doInitialSchematicTraceRender() {
5386
5386
  if (this.root?.schematicDisabled) return;
5387
- if (this.getGroup()?._getSchematicLayoutMode() === "match-adapt") return;
5388
5387
  const { db } = this.root;
5389
5388
  const { _parsedProps: props, parent } = this;
5390
5389
  if (!parent) throw new Error("Trace has no parent");
@@ -5414,7 +5413,7 @@ var Trace2 = class extends PrimitiveComponent2 {
5414
5413
  if (isPortAndNetConnection) {
5415
5414
  const net = netsWithSelectors[0].net;
5416
5415
  const { port, position: anchorPos } = portsWithPosition[0];
5417
- const connectedNetLabel = this.getSubcircuit().selectAll("netlabel").find((nl) => {
5416
+ let connectedNetLabel = this.getSubcircuit().selectAll("netlabel").find((nl) => {
5418
5417
  const conn = nl._parsedProps.connection ?? nl._parsedProps.connectsTo;
5419
5418
  if (!conn) return false;
5420
5419
  if (Array.isArray(conn)) {
@@ -5430,8 +5429,16 @@ var Trace2 = class extends PrimitiveComponent2 {
5430
5429
  });
5431
5430
  return targetPort === port;
5432
5431
  });
5432
+ if (!connectedNetLabel) {
5433
+ const dbNetLabel = db.schematic_net_label.getWhere({
5434
+ source_trace_id: this.source_trace_id
5435
+ });
5436
+ if (dbNetLabel) {
5437
+ connectedNetLabel = dbNetLabel;
5438
+ }
5439
+ }
5433
5440
  if (connectedNetLabel) {
5434
- const labelPos = connectedNetLabel._getGlobalSchematicPositionBeforeLayout();
5441
+ const labelPos = "_getGlobalSchematicPositionBeforeLayout" in connectedNetLabel ? connectedNetLabel._getGlobalSchematicPositionBeforeLayout() : connectedNetLabel.anchor_position;
5435
5442
  const edges2 = [];
5436
5443
  if (anchorPos.x === labelPos.x || anchorPos.y === labelPos.y) {
5437
5444
  edges2.push({ from: anchorPos, to: labelPos });
@@ -7221,227 +7228,182 @@ var normalizePinLabels = (inputPinLabels) => {
7221
7228
  };
7222
7229
 
7223
7230
  // lib/components/primitive-components/Group/Group_doInitialSchematicLayoutMatchAdapt.ts
7224
- import {
7225
- SchematicLayoutPipelineSolver,
7226
- reorderChipPinsToCcw,
7227
- convertCircuitJsonToInputNetlist,
7228
- getRefKey as getRefKey2
7229
- } from "@tscircuit/schematic-match-adapt";
7230
- import { circuitBuilderFromLayoutJson } from "@tscircuit/schematic-match-adapt";
7231
+ import "@tscircuit/schematic-match-adapt";
7232
+ import "@tscircuit/schematic-match-adapt";
7231
7233
 
7232
7234
  // lib/utils/schematic/deriveSourceTraceIdFromMatchAdaptPath.ts
7233
7235
  import {
7234
7236
  getRefKey,
7235
7237
  parseRefKey
7236
7238
  } from "@tscircuit/schematic-match-adapt";
7237
- function getConnectivityNetIdFromPortRef(pref, db) {
7238
- if ("boxId" in pref) {
7239
- const { boxId: sourceComponentName, pinNumber } = pref;
7240
- const sourceComp = db.source_component.getWhere({
7241
- name: sourceComponentName
7242
- });
7243
- if (!sourceComp) {
7244
- throw new Error(
7245
- `Source component "${sourceComponentName}" not found, but returned from match-adapt ${JSON.stringify(pref)}`
7246
- );
7247
- }
7248
- const sourcePort = db.source_port.getWhere({
7249
- source_component_id: sourceComp.source_component_id,
7250
- pin_number: pinNumber
7251
- });
7252
- return {
7253
- subcircuit_connectivity_map_key: sourcePort?.subcircuit_connectivity_map_key ?? null,
7254
- source_port_id: sourcePort.source_port_id
7255
- };
7256
- }
7257
- if ("netId" in pref) {
7258
- const { netId: sourceNetName } = pref;
7259
- const sourceNet = db.source_net.getWhere({ name: sourceNetName });
7260
- return null;
7261
- }
7262
- if ("junctionId" in pref) {
7263
- const { junctionId } = pref;
7264
- return null;
7265
- }
7266
- return null;
7267
- }
7268
- function deriveSourceTraceIdFromMatchAdaptPath({
7269
- path,
7270
- db,
7271
- layoutConnMap
7272
- }) {
7273
- let bestRef = getConnectivityNetIdFromPortRef(path.to, db) ?? getConnectivityNetIdFromPortRef(path.from, db);
7274
- if (!bestRef) {
7275
- const layoutConnNetId = layoutConnMap.getNetConnectedToId(
7276
- getRefKey(path.to)
7277
- );
7278
- const layoutConnectedRefs = layoutConnMap.getIdsConnectedToNet(layoutConnNetId).map((prefStr) => parseRefKey(prefStr));
7279
- bestRef = layoutConnectedRefs.map((ref) => getConnectivityNetIdFromPortRef(ref, db)).find(Boolean);
7280
- }
7281
- if (!bestRef?.subcircuit_connectivity_map_key) {
7282
- throw new Error(
7283
- `No connectivity net id found for match-adapt path ${JSON.stringify(path)}`
7284
- );
7285
- }
7286
- const sourceTraces = db.source_trace.list({
7287
- subcircuit_connectivity_map_key: bestRef.subcircuit_connectivity_map_key
7288
- });
7289
- for (const sourceTrace of sourceTraces) {
7290
- if (sourceTrace.connected_source_port_ids.includes(bestRef.source_port_id)) {
7291
- return sourceTrace.source_trace_id;
7292
- }
7293
- }
7294
- if (sourceTraces.length > 0) {
7295
- return sourceTraces[0].source_trace_id;
7296
- }
7297
- throw new Error(
7298
- `No source trace found for match-adapt path "${JSON.stringify(path)}"`
7299
- );
7300
- }
7301
7239
 
7302
7240
  // lib/components/primitive-components/Group/Group_doInitialSchematicLayoutMatchAdapt.ts
7303
- import { cju } from "@tscircuit/circuit-json-util";
7304
- import { ConnectivityMap as ConnectivityMap2 } from "circuit-json-to-connectivity-map";
7241
+ import "@tscircuit/circuit-json-util";
7242
+ import "circuit-json-to-connectivity-map";
7243
+ import corpus from "@tscircuit/schematic-corpus/dist/bundled-bpc-graphs.json";
7244
+ import { convertCircuitJsonToBpc } from "circuit-json-to-bpc";
7245
+ import {
7246
+ assignFloatingBoxPositions,
7247
+ netAdaptBpcGraph,
7248
+ getBpcGraphWlDistance
7249
+ } from "bpc-graph";
7250
+ import "@tscircuit/circuit-json-util";
7305
7251
  function Group_doInitialSchematicLayoutMatchAdapt(group) {
7306
7252
  const { db } = group.root;
7307
- let subtreeCircuitJson = structuredClone(db.toArray());
7308
- subtreeCircuitJson = reorderChipPinsToCcw(subtreeCircuitJson);
7309
- const inputNetlist = convertCircuitJsonToInputNetlist(subtreeCircuitJson);
7310
- const templateFns = group._parsedProps.matchAdaptTemplate ? [
7311
- () => circuitBuilderFromLayoutJson(
7312
- group._parsedProps.matchAdaptTemplate
7313
- )
7314
- ] : void 0;
7315
- const solver = new SchematicLayoutPipelineSolver({
7316
- inputNetlist,
7317
- templateFns
7318
- });
7319
- let solvedLayout = null;
7320
- try {
7321
- solver.solve();
7322
- solvedLayout = solver.getLayout();
7323
- } catch (e) {
7324
- db.schematic_layout_error.insert({
7325
- message: `Match-adapt layout failed: ${e.toString()}`,
7326
- error_type: "schematic_layout_error",
7327
- source_group_id: group.source_group_id,
7328
- schematic_group_id: group.schematic_group_id
7329
- });
7330
- return;
7331
- }
7332
- const { boxes, junctions, netLabels, paths } = solvedLayout;
7333
- const layoutConnMap = new ConnectivityMap2({});
7334
- for (const path of paths) {
7335
- layoutConnMap.addConnections([[getRefKey2(path.from), getRefKey2(path.to)]]);
7336
- }
7337
- for (const junction of junctions) {
7338
- for (const path of paths) {
7339
- for (const pathPoint of path.points) {
7340
- if (Math.abs(pathPoint.x - junction.x) < 1e-3 && Math.abs(pathPoint.y - junction.y) < 1e-3) {
7341
- layoutConnMap.addConnections([
7342
- [getRefKey2(path.from), getRefKey2(junction)],
7343
- [getRefKey2(path.to), getRefKey2(junction)]
7344
- ]);
7345
- }
7346
- }
7253
+ const subtreeCircuitJson = structuredClone(db.toArray());
7254
+ const existingLabels = new Set(
7255
+ subtreeCircuitJson.filter((e) => e.type === "schematic_net_label").map((e) => `${e.anchor_position?.x},${e.anchor_position?.y}`)
7256
+ );
7257
+ const oppositeSideFromFacing = {
7258
+ left: "right",
7259
+ right: "left",
7260
+ top: "bottom",
7261
+ bottom: "top"
7262
+ };
7263
+ const generatedNetLabels = /* @__PURE__ */ new Map();
7264
+ for (const sp of subtreeCircuitJson.filter(
7265
+ (e) => e.type === "schematic_port"
7266
+ )) {
7267
+ const key = `${sp.center.x},${sp.center.y}`;
7268
+ if (existingLabels.has(key)) continue;
7269
+ const srcPort = db.source_port.get(sp.source_port_id);
7270
+ const srcNet = db.source_net.getWhere({
7271
+ subcircuit_connectivity_map_key: srcPort?.subcircuit_connectivity_map_key
7272
+ });
7273
+ if (!srcNet) {
7274
+ console.error(`No source net found for port: ${sp.source_port_id}`);
7275
+ continue;
7347
7276
  }
7348
- }
7349
- for (const box of boxes) {
7350
- const srcComp = db.source_component.list().find((c) => c.name === box.boxId);
7351
- if (!srcComp) continue;
7352
- const schComp = db.schematic_component.getWhere({
7353
- source_component_id: srcComp.source_component_id
7354
- });
7355
- if (!schComp) continue;
7356
- const schCompMoveDelta = {
7357
- x: box.centerX - schComp.center.x + 0.1,
7358
- // TODO figure out why +0.1
7359
- y: box.centerY - schComp.center.y - 0.1
7277
+ const srcTrace = db.source_trace.getWhere({
7278
+ subcircuit_connectivity_map_key: srcPort?.subcircuit_connectivity_map_key
7279
+ });
7280
+ const schematic_net_label_id = `netlabel_for_${sp.schematic_port_id}`;
7281
+ const source_net = db.source_net.get(srcNet.source_net_id);
7282
+ const schematic_net_label = {
7283
+ type: "schematic_net_label",
7284
+ schematic_net_label_id,
7285
+ text: source_net.name,
7286
+ source_net_id: srcNet.source_net_id,
7287
+ source_trace_id: srcTrace?.source_trace_id,
7288
+ anchor_position: { ...sp.center },
7289
+ center: { ...sp.center },
7290
+ anchor_side: oppositeSideFromFacing[sp.facing_direction] ?? "right"
7360
7291
  };
7361
- db.schematic_component.update(schComp.schematic_component_id, {
7362
- center: {
7363
- x: schComp.center.x + schCompMoveDelta.x,
7364
- y: schComp.center.y + schCompMoveDelta.y
7365
- }
7292
+ generatedNetLabels.set(schematic_net_label_id, {
7293
+ schematic_net_label,
7294
+ schematic_port: sp
7366
7295
  });
7367
- const schematicPorts = db.schematic_port.list({
7368
- schematic_component_id: schComp.schematic_component_id
7369
- });
7370
- for (const schematicPort of schematicPorts) {
7371
- db.schematic_port.update(schematicPort.schematic_port_id, {
7372
- center: {
7373
- x: schematicPort.center.x + schCompMoveDelta.x,
7374
- y: schematicPort.center.y + schCompMoveDelta.y
7375
- }
7376
- });
7377
- }
7378
- const schematicTexts = db.schematic_text.list({
7379
- schematic_component_id: schComp.schematic_component_id
7380
- });
7381
- for (const schematicText of schematicTexts) {
7382
- db.schematic_text.update(schematicText.schematic_text_id, {
7383
- position: {
7384
- x: schematicText.position.x + schCompMoveDelta.x,
7385
- y: schematicText.position.y + schCompMoveDelta.y
7386
- }
7387
- });
7388
- }
7296
+ subtreeCircuitJson.push(schematic_net_label);
7389
7297
  }
7390
- for (const nl of netLabels) {
7391
- const srcNet = db.source_net.list().find((n) => n.name === nl.netId);
7392
- db.schematic_net_label.insert({
7393
- text: nl.netId,
7394
- source_net_id: srcNet?.source_net_id,
7395
- anchor_position: { x: nl.x, y: nl.y },
7396
- center: computeSchematicNetLabelCenter({
7397
- anchor_position: { x: nl.x, y: nl.y },
7398
- anchor_side: nl.anchorPosition,
7399
- text: nl.netId
7400
- }),
7401
- anchor_side: nl.anchorPosition
7402
- });
7298
+ const targetBpcGraph = convertCircuitJsonToBpc(subtreeCircuitJson);
7299
+ for (const box of targetBpcGraph.boxes) {
7300
+ if (box.kind === "fixed" || box.center) {
7301
+ box.kind = "floating";
7302
+ box.center = void 0;
7303
+ }
7403
7304
  }
7404
- for (const path of paths) {
7405
- if (!path.points || path.points.length < 2) continue;
7406
- const sourceTraceId = deriveSourceTraceIdFromMatchAdaptPath({
7407
- path,
7408
- db: cju(subtreeCircuitJson),
7409
- layoutConnMap
7410
- });
7411
- let edges = [];
7412
- for (let i = 0; i < path.points.length - 1; i++) {
7413
- edges.push({
7414
- from: {
7415
- x: path.points[i].x,
7416
- y: path.points[i].y
7417
- },
7418
- to: {
7419
- x: path.points[i + 1].x,
7420
- y: path.points[i + 1].y
7421
- }
7305
+ let bestMatch = {
7306
+ boxes: [],
7307
+ pins: []
7308
+ };
7309
+ let bestWlDistance = Infinity;
7310
+ let winningBpcGraphName = "empty";
7311
+ for (const [candidateBpcGraphName, candidateBpcGraph] of Object.entries(
7312
+ corpus
7313
+ ).sort((a, b) => a[0].localeCompare(b[0]))) {
7314
+ const wlDistance = getBpcGraphWlDistance(
7315
+ candidateBpcGraph,
7316
+ targetBpcGraph
7317
+ );
7318
+ console.log(candidateBpcGraphName, wlDistance);
7319
+ if (wlDistance < bestWlDistance) {
7320
+ bestMatch = candidateBpcGraph;
7321
+ winningBpcGraphName = candidateBpcGraphName;
7322
+ bestWlDistance = wlDistance;
7323
+ if (wlDistance === 0) break;
7324
+ }
7325
+ }
7326
+ console.log(`Winning BPC graph: ${winningBpcGraphName}`);
7327
+ const { adaptedBpcGraph } = netAdaptBpcGraph(
7328
+ bestMatch,
7329
+ targetBpcGraph
7330
+ );
7331
+ const adaptedBpcGraphWithPositions = assignFloatingBoxPositions(adaptedBpcGraph);
7332
+ for (const box of adaptedBpcGraphWithPositions.boxes) {
7333
+ const schematic_component2 = db.schematic_component.get(box.boxId);
7334
+ if (schematic_component2) {
7335
+ const ports = db.schematic_port.list({
7336
+ schematic_component_id: schematic_component2.schematic_component_id
7422
7337
  });
7423
- }
7424
- const otherCrossingEdges = getOtherSchematicTraces({
7425
- db,
7426
- source_trace_id: sourceTraceId,
7427
- differentNetOnly: true
7428
- }).flatMap((t) => t.edges);
7429
- if (otherCrossingEdges.length > 0) {
7430
- edges = createSchematicTraceCrossingSegments({
7431
- edges,
7432
- otherEdges: otherCrossingEdges
7338
+ const texts = db.schematic_text.list({
7339
+ schematic_component_id: schematic_component2.schematic_component_id
7433
7340
  });
7341
+ const positionDelta = {
7342
+ x: schematic_component2.center.x - box.center.x,
7343
+ y: schematic_component2.center.y - box.center.y
7344
+ };
7345
+ for (const port of ports) {
7346
+ port.center.x += positionDelta.x;
7347
+ port.center.y += positionDelta.y;
7348
+ }
7349
+ for (const text of texts) {
7350
+ text.position.x += positionDelta.x;
7351
+ text.position.y += positionDelta.y;
7352
+ }
7353
+ schematic_component2.center.x += positionDelta.x;
7354
+ schematic_component2.center.y += positionDelta.y;
7355
+ continue;
7434
7356
  }
7435
- const junctions2 = createSchematicTraceJunctions({
7436
- edges,
7437
- db,
7438
- source_trace_id: sourceTraceId
7439
- });
7440
- db.schematic_trace.insert({
7441
- source_trace_id: sourceTraceId,
7442
- edges,
7443
- junctions: junctions2
7444
- });
7357
+ const schematic_net_label = db.schematic_net_label.get(box.boxId);
7358
+ if (schematic_net_label) {
7359
+ const pin = adaptedBpcGraphWithPositions.pins.find(
7360
+ (p) => p.boxId === box.boxId && p.color === "netlabel_center"
7361
+ );
7362
+ if (!pin) {
7363
+ throw new Error(`No pin found for net label: ${box.boxId}`);
7364
+ }
7365
+ schematic_net_label.center = box.center;
7366
+ schematic_net_label.anchor_position = {
7367
+ x: box.center.x + pin.offset.x,
7368
+ y: box.center.y + pin.offset.y
7369
+ };
7370
+ continue;
7371
+ }
7372
+ if (generatedNetLabels.has(box.boxId)) {
7373
+ const { schematic_net_label: generatedNetLabel, schematic_port } = generatedNetLabels.get(box.boxId);
7374
+ const pins = adaptedBpcGraphWithPositions.pins.filter(
7375
+ (p) => p.boxId === box.boxId
7376
+ );
7377
+ const center = pins.find((p) => p.color === "netlabel_center");
7378
+ const anchor = pins.find((p) => p.color !== "netlabel_center");
7379
+ const color = anchor.color;
7380
+ const symbolName = color === "vcc" ? "vcc" : color === "gnd" ? "gnd" : void 0;
7381
+ const anchorSide = color === "vcc" ? "bottom" : color === "gnd" ? "top" : oppositeSideFromFacing[schematic_port.facing_direction] ?? "right";
7382
+ const source_net = db.source_net.get(generatedNetLabel.source_net_id);
7383
+ const schematic_net_label2 = {
7384
+ type: "schematic_net_label",
7385
+ schematic_net_label_id: `netlabel_for_${box.boxId}`,
7386
+ text: source_net.name,
7387
+ // no text; just a placeholder box for Match-Adapt
7388
+ anchor_position: {
7389
+ x: box.center.x + center.offset.x,
7390
+ y: box.center.y + center.offset.y
7391
+ },
7392
+ center: {
7393
+ x: box.center.x + center.offset.x,
7394
+ y: box.center.y + center.offset.y
7395
+ },
7396
+ anchor_side: anchorSide,
7397
+ symbol_name: symbolName,
7398
+ source_net_id: generatedNetLabel.source_net_id,
7399
+ source_trace_id: generatedNetLabel.source_trace_id
7400
+ };
7401
+ db.schematic_net_label.insert(schematic_net_label2);
7402
+ continue;
7403
+ }
7404
+ console.error(
7405
+ `No schematic element found for box: ${box.boxId}. This is a bug in the matchAdapt binding with @tscircuit/core`
7406
+ );
7445
7407
  }
7446
7408
  }
7447
7409
 
@@ -8021,15 +7983,11 @@ var Group = class extends NormalComponent {
8021
7983
  const debug4 = Debug5("tscircuit:core:_runLocalAutorouting");
8022
7984
  debug4(`[${this.getString()}] starting local autorouting`);
8023
7985
  const autorouterConfig = this._getAutorouterConfig();
8024
- const sourceTraceIdsToRoute = this.selectAll("trace").filter((t) => !t.pcb_trace_id).map((t) => t.source_trace_id);
8025
7986
  const { simpleRouteJson } = getSimpleRouteJsonFromCircuitJson({
8026
7987
  db,
8027
7988
  minTraceWidth: this.props.autorouter?.minTraceWidth ?? 0.15,
8028
7989
  subcircuit_id: this.subcircuit_id
8029
7990
  });
8030
- simpleRouteJson.connections = simpleRouteJson.connections.filter(
8031
- (conn) => sourceTraceIdsToRoute.includes(conn.name)
8032
- );
8033
7991
  this.root?.emit("autorouting:start", {
8034
7992
  subcircuit_id: this.subcircuit_id,
8035
7993
  componentDisplayName: this.getString(),
@@ -10708,7 +10666,7 @@ import { identity as identity4 } from "transformation-matrix";
10708
10666
  var package_default = {
10709
10667
  name: "@tscircuit/core",
10710
10668
  type: "module",
10711
- version: "0.0.532",
10669
+ version: "0.0.534",
10712
10670
  types: "dist/index.d.ts",
10713
10671
  main: "dist/index.js",
10714
10672
  module: "dist/index.js",
@@ -10733,7 +10691,7 @@ var package_default = {
10733
10691
  "@biomejs/biome": "^1.8.3",
10734
10692
  "@tscircuit/capacity-autorouter": "^0.0.75",
10735
10693
  "@tscircuit/checks": "^0.0.52",
10736
- "@tscircuit/circuit-json-util": "^0.0.49",
10694
+ "@tscircuit/circuit-json-util": "^0.0.50",
10737
10695
  "@tscircuit/footprinter": "^0.0.186",
10738
10696
  "@tscircuit/import-snippet": "^0.0.4",
10739
10697
  "@tscircuit/infgrid-ijump-astar": "^0.0.33",
@@ -10742,6 +10700,7 @@ var package_default = {
10742
10700
  "@tscircuit/math-utils": "^0.0.18",
10743
10701
  "@tscircuit/props": "^0.0.246",
10744
10702
  "@tscircuit/schematic-autolayout": "^0.0.6",
10703
+ "@tscircuit/schematic-corpus": "^0.0.29",
10745
10704
  "@tscircuit/schematic-match-adapt": "^0.0.16",
10746
10705
  "@tscircuit/simple-3d-svg": "^0.0.6",
10747
10706
  "@types/bun": "^1.2.16",
@@ -10749,15 +10708,18 @@ var package_default = {
10749
10708
  "@types/react": "^19.0.1",
10750
10709
  "@types/react-dom": "^19.0.2",
10751
10710
  "@types/react-reconciler": "^0.28.9",
10711
+ "bpc-graph": "^0.0.16",
10752
10712
  "bun-match-svg": "0.0.11",
10713
+ "calculate-elbow": "^0.0.5",
10753
10714
  "chokidar-cli": "^3.0.0",
10754
10715
  "circuit-json": "^0.0.212",
10716
+ "circuit-json-to-bpc": "^0.0.7",
10755
10717
  "circuit-json-to-connectivity-map": "^0.0.22",
10756
10718
  "circuit-json-to-simple-3d": "^0.0.2",
10757
10719
  "circuit-to-svg": "^0.0.162",
10758
10720
  concurrently: "^9.1.2",
10759
10721
  debug: "^4.3.6",
10760
- "graphics-debug": "^0.0.4",
10722
+ "graphics-debug": "^0.0.57",
10761
10723
  howfat: "^0.3.8",
10762
10724
  "live-server": "^1.2.2",
10763
10725
  "looks-same": "^9.0.1",
@@ -10778,6 +10740,9 @@ var package_default = {
10778
10740
  "@tscircuit/props": "*",
10779
10741
  "@tscircuit/schematic-autolayout": "*",
10780
10742
  "@tscircuit/schematic-match-adapt": "*",
10743
+ "@tscircuit/schematic-corpus": "*",
10744
+ "circuit-json-to-bpc": "*",
10745
+ "bpc-graph": "*",
10781
10746
  "circuit-json": "*",
10782
10747
  "circuit-json-to-connectivity-map": "*",
10783
10748
  "schematic-symbols": "*",
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@tscircuit/core",
3
3
  "type": "module",
4
- "version": "0.0.533",
4
+ "version": "0.0.535",
5
5
  "types": "dist/index.d.ts",
6
6
  "main": "dist/index.js",
7
7
  "module": "dist/index.js",
@@ -26,7 +26,7 @@
26
26
  "@biomejs/biome": "^1.8.3",
27
27
  "@tscircuit/capacity-autorouter": "^0.0.75",
28
28
  "@tscircuit/checks": "^0.0.52",
29
- "@tscircuit/circuit-json-util": "^0.0.49",
29
+ "@tscircuit/circuit-json-util": "^0.0.50",
30
30
  "@tscircuit/footprinter": "^0.0.186",
31
31
  "@tscircuit/import-snippet": "^0.0.4",
32
32
  "@tscircuit/infgrid-ijump-astar": "^0.0.33",
@@ -35,6 +35,7 @@
35
35
  "@tscircuit/math-utils": "^0.0.18",
36
36
  "@tscircuit/props": "^0.0.246",
37
37
  "@tscircuit/schematic-autolayout": "^0.0.6",
38
+ "@tscircuit/schematic-corpus": "^0.0.29",
38
39
  "@tscircuit/schematic-match-adapt": "^0.0.16",
39
40
  "@tscircuit/simple-3d-svg": "^0.0.6",
40
41
  "@types/bun": "^1.2.16",
@@ -42,15 +43,18 @@
42
43
  "@types/react": "^19.0.1",
43
44
  "@types/react-dom": "^19.0.2",
44
45
  "@types/react-reconciler": "^0.28.9",
46
+ "bpc-graph": "^0.0.16",
45
47
  "bun-match-svg": "0.0.11",
48
+ "calculate-elbow": "^0.0.5",
46
49
  "chokidar-cli": "^3.0.0",
47
50
  "circuit-json": "^0.0.212",
51
+ "circuit-json-to-bpc": "^0.0.7",
48
52
  "circuit-json-to-connectivity-map": "^0.0.22",
49
53
  "circuit-json-to-simple-3d": "^0.0.2",
50
54
  "circuit-to-svg": "^0.0.162",
51
55
  "concurrently": "^9.1.2",
52
56
  "debug": "^4.3.6",
53
- "graphics-debug": "^0.0.4",
57
+ "graphics-debug": "^0.0.57",
54
58
  "howfat": "^0.3.8",
55
59
  "live-server": "^1.2.2",
56
60
  "looks-same": "^9.0.1",
@@ -71,6 +75,9 @@
71
75
  "@tscircuit/props": "*",
72
76
  "@tscircuit/schematic-autolayout": "*",
73
77
  "@tscircuit/schematic-match-adapt": "*",
78
+ "@tscircuit/schematic-corpus": "*",
79
+ "circuit-json-to-bpc": "*",
80
+ "bpc-graph": "*",
74
81
  "circuit-json": "*",
75
82
  "circuit-json-to-connectivity-map": "*",
76
83
  "schematic-symbols": "*",