Du kannst nicht mehr als 25 Themen auswählen Themen müssen entweder mit einem Buchstaben oder einer Ziffer beginnen. Sie können Bindestriche („-“) enthalten und bis zu 35 Zeichen lang sein.

27 Zeilen
1.7KB

  1. # Loads the Foundry Knowledge Engine commands for this project. Generated by the C64/C128 Dev Foundry.
  2. # Use: . ./tools/knowledge.ps1 (dot-source it, then see skills/knowledge-management/SKILL.md)
  3. # The knowledge system is shared across projects and lives in the Foundry that generated this repo.
  4. # Locations tried, in order: $env:FOUNDRY_HOME, then generated.foundryRoot in project.json.
  5. # This script never changes the project's build; it only imports the module and sets the project key.
  6. $repoRoot = (Resolve-Path -LiteralPath (Join-Path $PSScriptRoot '..')).Path
  7. $project = Get-Content -LiteralPath (Join-Path $repoRoot 'project.json') -Raw | ConvertFrom-Json -Depth 64
  8. $tried = [System.Collections.Generic.List[string]]::new()
  9. $module = $null
  10. foreach ($root in @($env:FOUNDRY_HOME, $project.generated.foundryRoot)) {
  11. if (-not $root) { continue }
  12. $candidate = Join-Path $root 'powershell/Foundry.Knowledge/Foundry.Knowledge.psd1'
  13. $tried.Add($candidate)
  14. if (Test-Path -LiteralPath $candidate) { $module = $candidate; break }
  15. }
  16. if (-not $module) {
  17. Write-Warning ("Foundry Knowledge module not found. Tried: " + ($tried -join '; ') + ". Set FOUNDRY_HOME to the Foundry folder, then run again. Continue without stored knowledge and tell the user.")
  18. return
  19. }
  20. Import-Module $module -Force -Global
  21. Set-FoundryProjectContext -Project $project.project.slug
  22. $status = Test-FoundryKnowledge
  23. Write-Host ("Foundry knowledge: project '{0}', ready={1}, embeddings={2}" -f $project.project.slug, $status.Ready, $status.EmbeddingsReady)
  24. if (-not $status.Ready) {
  25. $status.Checks | Where-Object { -not $_.ok } | ForEach-Object { Write-Warning "$($_.check): $($_.detail)" }
  26. }

Powered by TurnKey Linux.