ThatAIguyA world of ideas

THE CONSCIOUSNESS ATLAS
Read. Experiment. Follow the evidence.

ConsciousnessLearn · Explore · Joseph Anady

Janady13/missionmatch / internal/modules/matching/intelligence/intelligence_test.go

Source identity, revision, and recovered contents.

GitHub sourceSource text recovered

Source identity

FieldRecorded value
Source typeGitHub source
Original recordJanady13/missionmatch / internal/modules/matching/intelligence/intelligence_test.go
DateNot specified in source
RepositoryJanady13/missionmatch
Revision09015496d565a172bcaa15cfe9a8e4b072b13df0
Branchworkstream-b-screenmatch
Path or archive memberinternal/modules/matching/intelligence/intelligence_test.go
Original SHA-2561062239778179876be65caac9ada7da3c99818a774706aa38d9b8e604235b170
Git blob SHA2b65117af1bed16f46d9b873e0e7a84113e211d9
Reading-copy SHA-2561062239778179876be65caac9ada7da3c99818a774706aa38d9b8e604235b170

Original source ↗

Every recorded occurrence

These 35 records contain identical original source bytes. Their paths and revisions remain part of the archive.

Original recordBranch or archiveRevision / identifierOriginal location
Janady13/missionmatch / internal/modules/matching/intelligence/intelligence_test.goworkstream-b-screenmatch09015496d565a172bcaa15cfe9a8e4b072b13df0Open original
Janady13/missionmatch / internal/modules/matching/intelligence/intelligence_test.goworkstream-a-opportunity-intelligence1675031db74316e100782d063e9eda1a597fe3a1Open original
Janady13/missionmatch / internal/modules/matching/intelligence/intelligence_test.goworkstream-d-command-center255e7d1d420abf5e277d0cd8c9b14f6f72b6acb9Open original
Janady13/missionmatch / internal/modules/matching/intelligence/intelligence_test.goworkstream-d-missionmatch3be46ba89edb737182075a2b320509b42dc916f8Open original
Janady13/missionmatch / internal/modules/matching/intelligence/intelligence_test.goworkstream-e-dataflow-deploy433815a042f9741411e60fa553fe72143e9b10dbOpen original
Janady13/missionmatch / internal/modules/matching/intelligence/intelligence_test.gow3-ai-staffing-recommendations43d56387270ef4da4cabd794d97ca6a49909bc7dOpen original
Janady13/missionmatch / internal/modules/matching/intelligence/intelligence_test.goworkstream-e-commercial-stubs4437da660539284a400ee380b9b427a300c369eeOpen original
Janady13/missionmatch / internal/modules/matching/intelligence/intelligence_test.gows3-clearance4b8e7ce594c068621867f9c9deed0ec64ae6c553Open original
Janady13/missionmatch / internal/modules/matching/intelligence/intelligence_test.goworkstream-c-slatematch5cd60c918301b46ecd6ed3e03e20c395da0062e2Open original
Janady13/missionmatch / internal/modules/matching/intelligence/intelligence_test.goai-intelligence-layer5d5ddff70393a197c5f54a45280bb5dd42b24755Open original
Janady13/missionmatch / internal/modules/matching/intelligence/intelligence_test.goper-tenant-routing9bde0f9a74b89d01980fa658e5253acda7528d0cOpen original
Janady13/missionmatch / internal/modules/matching/intelligence/intelligence_test.goai-brain-liveaac32fc49c878cc5bca099459307611562d0bac1Open original
Janady13/missionmatch / internal/modules/matching/intelligence/intelligence_test.gows1-ontology-syncb596f449a32a1016fbd403c36505cc00a1ac9ee6Open original
Janady13/missionmatch / internal/modules/matching/intelligence/intelligence_test.goruthless-debug-sweepb7d742f8f032984be3817efffa3eb8b13b651c1fOpen original
Janady13/missionmatch / internal/modules/matching/intelligence/intelligence_test.godeploy-and-opsbdacd9d0b4d5998d25fc74bf4007f4c3ec538c7aOpen original
Janady13/missionmatch / internal/modules/matching/intelligence/intelligence_test.goworkstream-b-sam-contract-awardsd5101cceb98e70000cebb31d3e7ac73d747d3a6dOpen original
Janady13/missionmatch / internal/modules/matching/intelligence/intelligence_test.goworkstream-a-shared-coree0de03ac3a1ec826bd15d0e048e3b02baa23eeffOpen original
Janady13/missionmatch / internal/modules/matching/intelligence/intelligence_test.gows2-alias-relationshipe4dada4601c6eb101830f9d223a9655dfa120616Open original
Janady13/missionmatch / internal/modules/matching/intelligence/intelligence_test.goper-tenant-routing9bde0f9a74b89d01980fa658e5253acda7528d0cOpen original
Janady13/missionmatch / internal/modules/matching/intelligence/intelligence_test.goworkstream-a-shared-coree0de03ac3a1ec826bd15d0e048e3b02baa23eeffOpen original
Janady13/missionmatch / internal/modules/matching/intelligence/intelligence_test.goworkstream-c-slatematch5cd60c918301b46ecd6ed3e03e20c395da0062e2Open original
Janady13/missionmatch / internal/modules/matching/intelligence/intelligence_test.gows1-ontology-syncb596f449a32a1016fbd403c36505cc00a1ac9ee6Open original
Janady13/missionmatch / internal/modules/matching/intelligence/intelligence_test.gow3-ai-staffing-recommendations43d56387270ef4da4cabd794d97ca6a49909bc7dOpen original
Janady13/missionmatch / internal/modules/matching/intelligence/intelligence_test.gows3-clearance4b8e7ce594c068621867f9c9deed0ec64ae6c553Open original
Janady13/missionmatch / internal/modules/matching/intelligence/intelligence_test.goworkstream-d-command-center255e7d1d420abf5e277d0cd8c9b14f6f72b6acb9Open original
Janady13/missionmatch / internal/modules/matching/intelligence/intelligence_test.goworkstream-e-dataflow-deploy433815a042f9741411e60fa553fe72143e9b10dbOpen original
Janady13/missionmatch / internal/modules/matching/intelligence/intelligence_test.goruthless-debug-sweepb7d742f8f032984be3817efffa3eb8b13b651c1fOpen original
Janady13/missionmatch / internal/modules/matching/intelligence/intelligence_test.goai-intelligence-layer5d5ddff70393a197c5f54a45280bb5dd42b24755Open original
Janady13/missionmatch / internal/modules/matching/intelligence/intelligence_test.goworkstream-a-opportunity-intelligence1675031db74316e100782d063e9eda1a597fe3a1Open original
Janady13/missionmatch / internal/modules/matching/intelligence/intelligence_test.godeploy-and-opsbdacd9d0b4d5998d25fc74bf4007f4c3ec538c7aOpen original
Janady13/missionmatch / internal/modules/matching/intelligence/intelligence_test.goworkstream-b-screenmatch09015496d565a172bcaa15cfe9a8e4b072b13df0Open original
Janady13/missionmatch / internal/modules/matching/intelligence/intelligence_test.goworkstream-e-commercial-stubs4437da660539284a400ee380b9b427a300c369eeOpen original
Janady13/missionmatch / internal/modules/matching/intelligence/intelligence_test.goai-brain-liveaac32fc49c878cc5bca099459307611562d0bac1Open original
Janady13/missionmatch / internal/modules/matching/intelligence/intelligence_test.goworkstream-d-missionmatch3be46ba89edb737182075a2b320509b42dc916f8Open original
Janady13/missionmatch / internal/modules/matching/intelligence/intelligence_test.goworkstream-b-sam-contract-awardsd5101cceb98e70000cebb31d3e7ac73d747d3a6dOpen original

Recovered source transcript

package intelligence import ( "context" "testing" "time" "github.com/missionworkforce/missionmatch/internal/modules/matching/engine" ) // perfect candidate vs a Secret/DISA/5yr requirement => total 100, green. func perfect() (engine.Candidate, engine.Requirement, engine.MatchResult) { c := engine.Candidate{ ID: "c1", Clearance: engine.Clearance{Level: engine.ClearanceTSSCI, Poly: engine.PolyFullScope, Status: engine.StatusActive}, Certifications: []string{"Security+"}, CustomerExperience: []string{"DISA"}, YearsExperience: 10, Available: true, } r := engine.Requirement{ ID: "r1", RequiredLevel: engine.ClearanceSecret, CustomerAgency: "DISA", RequiredCerts: []string{"Security+"}, RequiredYears: 5, KeyPersonnel: true, } return c, r, engine.ScoreCandidate(context.Background(), c, r, nil) } func TestReadinessMapsToMissionLanguage(t *testing.T) { _, _, res := perfect() mr := Readiness(res) if mr.Status != "Mission Ready" || mr.StatusCode != "ready" || mr.Band != "green" { t.Fatalf("expected Mission Ready/green, got %+v", mr) } if mr.Score != "100.00" { t.Fatalf("score = %s, want 100.00", mr.Score) } if len(mr.Categories) != 6 { t.Fatalf("expected 6 readiness categories, got %d", len(mr.Categories)) } want := map[string]bool{ "Clearance Readiness": true, "Skills Readiness": true, "Certification Readiness": true, "Customer Readiness": true, "Experience Readiness": true, "Availability Readiness": true, } for _, cat := range mr.Categories { if !want[cat.Name] { t.Errorf("unexpected category name %q", cat.Name) } if cat.State != "ready" { t.Errorf("category %s state = %s, want ready", cat.Name, cat.State) } } } func TestReadinessStatesAcrossBands(t *testing.T) { // Confidential candidate vs a Secret requirement => clearance 0 (gap), total 75 (yellow). c := engine.Candidate{ID: "c", Clearance: engine.Clearance{Level: engine.ClearanceConfidential, Status: engine.StatusActive}, Available: true} r := engine.Requirement{ID: "r", RequiredLevel: engine.ClearanceSecret} mr := Readiness(engine.ScoreCandidate(context.Background(), c, r, nil)) if mr.StatusCode != "review" { t.Fatalf("expected review, got %s (score %s)", mr.StatusCode, mr.Score) } for _, cat := range mr.Categories { if cat.Name == "Clearance Readiness" && cat.State != "gap" { t.Fatalf("clearance should be a gap, got %s", cat.State) } } } func TestNextStepsByBand(t *testing.T) { _, _, green := perfect() if NextSteps(green)[0].Action != "Move to Candidate Slate" { t.Fatalf("green first step wrong: %+v", NextSteps(green)) } red := engine.ScoreCandidate(context.Background(), engine.Candidate{ID: "c"}, engine.Requirement{ID: "r", RequiredLevel: engine.ClearanceTSSCI}, nil) if NextSteps(red)[0].Action != "Recruit Additional Candidates" { t.Fatalf("red first step wrong: %+v", NextSteps(red)) } } func TestBattleCardStrengthsAndGaps(t *testing.T) { c, r, res := perfect() bc := BattleCardFor(c, r, res) hasStrength := func(sub string) bool { for _, s := range bc.Strengths { if s == sub { return true } } return false } if !hasStrength("TS/SCI Active") { t.Fatalf("expected 'TS/SCI Active' strength, got %v", bc.Strengths) } if !hasStrength("DISA experience") || !hasStrength("Security+") { t.Fatalf("expected DISA + Security+ strengths, got %v", bc.Strengths) } if len(bc.Gaps) != 0 { t.Fatalf("perfect candidate should have no gaps, got %v", bc.Gaps) } // A candidate missing a mandatory skill should surface it as a gap. c2 := engine.Candidate{ID: "c2", Clearance: engine.Clearance{Level: engine.ClearanceSecret, Status: engine.StatusActive}, Available: true} r2 := engine.Requirement{ID: "r2", RequiredLevel: engine.ClearanceSecret, RequiredSkills: []engine.RequiredSkill{{SkillID: "go", Name: "Go", Mandatory: true}}} res2 := engine.ScoreCandidate(context.Background(), c2, r2, nil) bc2 := BattleCardFor(c2, r2, res2) if len(bc2.Gaps) == 0 { t.Fatalf("expected a gap for the missing mandatory skill") } } func TestClearanceIntelligence(t *testing.T) { asOf := time.Date(2026, 6, 23, 0, 0, 0, 0, time.UTC) granted := asOf.AddDate(-3, 0, 0) // 36 months ago expires := asOf.AddDate(0, 1, 0) // not expired ci := Clearance(ClearanceFacts{ Level: engine.ClearanceTSSCI, Poly: engine.PolyFullScope, Status: engine.StatusActive, GrantedAt: &granted, ExpiresAt: &expires, CustomerAgencies: []string{"DISA"}, }, asOf) if ci.Current != "TS/SCI" || !ci.SCIEligible || !ci.FullScopePoly || !ci.CIPolyEligible { t.Fatalf("clearance intel wrong: %+v", ci) } if ci.Expired { t.Fatal("should not be expired") } if ci.InvestigationAgeMonths == nil || *ci.InvestigationAgeMonths != 36 { t.Fatalf("investigation age should be 36 months, got %v", ci.InvestigationAgeMonths) } if !ci.RecentClassifiedSupport { t.Fatal("should have recent classified support (has DISA)") } // expired clearance exp := asOf.AddDate(0, 0, -1) ci2 := Clearance(ClearanceFacts{Level: engine.ClearanceSecret, Status: engine.StatusActive, ExpiresAt: &exp}, asOf) if !ci2.Expired || ci2.SCIEligible { t.Fatalf("expected expired + not SCI eligible, got %+v", ci2) } } func TestContractReadinessAreasAndRisks(t *testing.T) { c, r, res := perfect() asOf := time.Date(2026, 6, 23, 0, 0, 0, 0, time.UTC) soon := asOf.AddDate(0, 0, 30) // expires in 30 days => risk cr := Contract(c, r, res, ClearanceFacts{ExpiresAt: &soon, CustomerAgencies: []string{"DISA"}}, asOf) if len(cr.Areas) != 5 { t.Fatalf("expected 5 contract areas, got %d", len(cr.Areas)) } for _, a := range cr.Areas { if !a.Met { t.Fatalf("perfect candidate should meet area %q", a.Area) } } foundExpiry := false for _, risk := range cr.Risks { if risk.Severity == "warning" && contains(risk.Message, "expires in 30 days") { foundExpiry = true } } if !foundExpiry { t.Fatalf("expected a clearance-expiry risk, got %+v", cr.Risks) } } func TestWinImpact(t *testing.T) { c, r, res := perfect() wi := Win(c, r, res) if wi.LevelCode != "high" || wi.Level != "High Impact" { t.Fatalf("perfect+keypersonnel should be High Impact, got %+v", wi) } if wi.StaffingStrength != "100.00" { t.Fatalf("staffing strength = %s, want 100.00", wi.StaffingStrength) } hasReason := func(sub string) bool { for _, rsn := range wi.Reasons { if rsn == sub { return true } } return false } if !hasReason("Active TS/SCI") || !hasReason("Matches Key Personnel requirements") { t.Fatalf("expected TS/SCI + Key Personnel reasons, got %v", wi.Reasons) } } func contains(s, sub string) bool { return len(s) >= len(sub) && (func() bool { for i := 0; i+len(sub) <= len(s); i++ { if s[i:i+len(sub)] == sub { return true } } return false })() }

Search equations, builds, manuscript text, and recovered sources.