Commit Graph
7 Commits
Author SHA1 Message Date
Sharang ParnerkarandClaude Opus 5.5 062b34105a feat(graph): PLC programs, function blocks and functions in the code graph (t82)
CI / Check (push) Skipped
CI / Detect Changes (pull_request) Skipped
CI / Agent integration (pull_request) Successful in 4m35s
CI / Deploy Agent (pull_request) Skipped
CI / Deploy Dashboard (pull_request) Skipped
CI / Deploy Docs (pull_request) Skipped
CI / Deploy MCP (pull_request) Skipped
CI / Check (pull_request) Successful in 18m35s
A PLC target now gets a code graph. Before this, PLC targets skipped the
graph phase entirely.

Nodes:
- A PROGRAM is a module and an entry point.
- A FUNCTION_BLOCK is a class.
- A FUNCTION is a function.

Edges:
- A variable whose type is a function block is a type reference to it.
- A call through an instance is a call to its type.
- Calls by name are calls.
- Standard blocks such as TON have no node, so their edges are dropped.

How it fits together:
- The PLC module reads each tree once, and both the findings and the
  graph come from that read.
- The engine gets a public assemble step for nodes parsed outside the
  graph crate, and FileGraph is public with line-based adders.
- One build function takes a tree or a PLC project's POUs. The scan
  uses it, and so does the explorer's manual rebuild, which would
  otherwise replace a PLC target's graph with file nodes only.

POU spans:
- A POU records the line of its END_ keyword.
- A PLCopen POU spans its <pou> element in the XML. Its statements keep
  their synthetic lines, so finding lines and fingerprints don't change.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-07 04:12:18 +01:00
Sharang ParnerkarandClaude Opus 5.5 6a2b56585e feat(graph): C and C# in the code graph (t82)
CI / Check (push) Skipped
CI / Detect Changes (pull_request) Skipped
CI / Deploy Agent (pull_request) Skipped
CI / Deploy Dashboard (pull_request) Skipped
CI / Deploy Docs (pull_request) Skipped
CI / Deploy MCP (pull_request) Skipped
CI / Agent integration (pull_request) Successful in 4m38s
CI / Check (pull_request) Successful in 18m45s
Customer code is mostly C firmware and C#/ASP.NET, which the graph didn't
parse, so their graphs were nearly empty.

- C: functions, structs, unions, enums (including typedef'd ones and those
  inside #if blocks), calls by name and #includes. main and interrupt
  handlers are entry points, in the avr-gcc ISR(), CodeVision, SDCC, IAR and
  GCC attribute spellings.
- C#: classes, structs, interfaces, records, enums, methods and
  constructors, base types (Implements for IName), calls and constructions.
  Entry points are Main and what a web framework calls: controller actions,
  [Http*]/[Route]/[WebMethod] methods, Razor page handlers, Web Forms
  pages and controls, IHttpHandler.ProcessRequest.
- Overloads and #ifdef/#else alternatives share one qualified name: they
  give one node (an entry point if any of them is), and the calls of every
  body count. Before, the graph kept the last and orphaned the others.
- tree-sitter-c 0.23.4; tree-sitter-c-sharp pinned to 0.23.1, as 0.23.5 is
  built for grammar ABI 15 and our tree-sitter 0.24 reads up to 14.
- Edge resolution goes through an index by last name segment instead of
  scanning every node per edge. When several nodes match it prefers the
  edge's own file (C static functions), then the first by name, so a
  rebuild links the same way. #include "uart.h" now links to the header.
- Community detection kept its totals up to date only by re-summing all
  nodes for every node (quadratic per pass), and ran twice per build. It
  now costs O(nodes + edges) per pass and runs once, in the build. The
  FreeRTOS kernel (6,500 nodes) builds in 1.2 s instead of 6.9 s.
- compliance-graph joins CI's clippy and test steps. Its tests never ran
  in CI before. The Rust parser's tests move below its last impl (clippy).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-07 04:12:17 +01:00
sharang 4388e98b5b feat: add E2E test suite with nightly CI, fix dashboard Dockerfile (#52)
CI / Check (push) Has been skipped
CI / Detect Changes (push) Successful in 2s
CI / Deploy Agent (push) Successful in 2s
CI / Deploy Dashboard (push) Successful in 2s
CI / Deploy Docs (push) Has been skipped
CI / Deploy MCP (push) Has been skipped
2026-03-30 10:04:07 +00:00
sharang 3bb690e5bb refactor: modularize codebase and add 404 unit tests (#13)
CI / Format (push) Successful in 4s
CI / Clippy (push) Successful in 4m19s
CI / Detect Changes (push) Successful in 5s
CI / Tests (push) Successful in 5m15s
CI / Deploy Agent (push) Successful in 2s
CI / Deploy Dashboard (push) Successful in 2s
CI / Deploy Docs (push) Has been skipped
CI / Deploy MCP (push) Successful in 2s
CI / Security Audit (push) Successful in 1m44s
2026-03-13 08:03:45 +00:00
sharangandSharang Parnerkar 42cabf0582 feat: rag-embedding-ai-chat (#1)
CI / Format (push) Successful in 2s
CI / Clippy (push) Successful in 2m56s
CI / Security Audit (push) Successful in 1m25s
CI / Tests (push) Successful in 3m57s
Co-authored-by: Sharang Parnerkar <parnerkarsharang@gmail.com>
Reviewed-on: https://gitea.meghsakha.com/sharang/compliance-scanner-agent/pulls/1
2026-03-06 21:54:15 +00:00
Sharang ParnerkarandClaude Opus 4.6 b18824db25 Add graph explorer components, API handlers, and dependency updates
Adds code inspector, file tree components, graph visualization JS,
graph API handlers, sidebar navigation updates, and misc improvements.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-04 21:52:49 +01:00
Sharang ParnerkarandClaude Opus 4.6 cea8f59e10 Add DAST, graph modules, toast notifications, and dashboard enhancements
Add DAST scanning and code knowledge graph features across the stack:
- compliance-dast and compliance-graph workspace crates
- Agent API handlers and routes for DAST targets/scans and graph builds
- Core models and traits for DAST and graph domains
- Dashboard pages for DAST targets/findings/overview and graph explorer/impact
- Toast notification system with auto-dismiss for async action feedback
- Button click animations and disabled states for better UX

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-04 13:53:50 +01:00