Documentation
¶
Index ¶
Examples ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Applicability ¶
type Applicability struct {
// Inclusion by geographical or legal areas
Jurisdictions []string `json:"jurisdictions,omitempty" yaml:"jurisdictions,omitempty"`
// Inclusion by types of technology or technological environments
TechnologyDomains []string `json:"technology-domains,omitempty" yaml:"technology-domains,omitempty"`
// Inclusion by industry sectors or verticals
IndustrySectors []string `json:"industry-sectors,omitempty" yaml:"industry-sectors,omitempty"`
}
type Category ¶
type Category struct {
Id string `json:"id" yaml:"id"`
Title string `json:"title" yaml:"title"`
Description string `json:"description" yaml:"description"`
Guidelines []Guideline `json:"guidelines,omitempty" yaml:"guidelines,omitempty"`
}
Category represents a logical group of guidelines (i.e. control family)
type DocumentType ¶
type DocumentType string
type GuidanceDocument ¶
type GuidanceDocument struct {
Metadata Metadata `json:"metadata,omitempty" yaml:"metadata,omitempty"`
// Introductory text for the document to be used during rendering
FrontMatter string `json:"front-matter,omitempty" yaml:"front-matter,omitempty"`
Categories []Category `json:"categories,omitempty" yaml:"categories,omitempty"`
// For inheriting from other guidance documents to create tailored documents/baselines
ImportedGuidelines []Mapping `json:"imported-guidelines,omitempty" yaml:"imported-guidelines,omitempty"`
ImportedPrinciples []Mapping `json:"imported-principles,omitempty" yaml:"imported-principles,omitempty"`
}
Example ¶
tmpl := `
# {{ .Metadata.Title }} ({{ .Metadata.Id }})
---
**Front Matter:** {{ .FrontMatter }}
---
{{ range .Categories }}
### {{ .Title }} ({{ .Id }})
{{ .Description }}
#### Guidelines:
{{ range .Guidelines }}
##### {{ .Title }} ({{ .Id }})
**Objective:** {{ .Objective }}
{{ if .SeeAlso }}
**See Also:** {{ range .SeeAlso }}{{ . }} {{ end }}
{{ end }}
{{ end }}
{{ end }}
`
l1Docs := GuidanceDocument{
Metadata: Metadata{
Id: "FINOS-AIR",
Title: "AI Governance Framework",
MappingReferences: []MappingReference{
{
Id: "NIST-800-53",
Title: "NIST SP 800-53r5",
Version: "rev5",
Url: "https://nvlpubs.nist.gov/nistpubs/SpecialPublications/NIST.SP.800-53r5.pdf#%5B%7B%22num%22%3A342%2C%22gen%22%3A0%7D%2C%7B%22name%22%3A%22XYZ%22%7D%2C88%2C310%2C0%5D",
},
{
Id: "AIR-PRIN",
Title: "Example Principles Document for the Framework",
Version: "0.1.0",
},
},
DocumentType: "Framework",
Applicabilty: &Applicability{
TechnologyDomains: []string{
"artificial-intelligence",
},
IndustrySectors: []string{
"financial-services",
},
},
},
FrontMatter: "The following framework has been developed by FINOS (Fintech Open Source Foundation).",
Categories: []Category{
{
Id: "DET",
Title: "Detective",
Description: "Detection and Continuous Improvement",
Guidelines: []Guideline{
{
Id: "AIR-DET-011",
Title: "Human Feedback Loop for AI Systems",
Objective: "A Human Feedback Loop is a critical detective and continuous improvement mechanism that involves systematically collecting, " +
"analyzing, and acting upon feedback provided by human users, subject matter experts (SMEs), or reviewers regarding an AI system’s performance, outputs, or behavior.",
Rationale: &Rationale{
Risks: []Risk{},
Outcomes: []Outcome{
{
Title: "Governance Support",
Description: "Provides data for AI governance bodies to monitor impact and make decisions",
},
},
},
GuidelineParts: []Part{
{
Id: "AIR-DET-011.1",
Title: "Designing the Feedback Mechanism",
Prose: "Implementing an effective human feedback loop involves careful design of the mechanism.",
Recommendations: []string{
"Define Intended Use and KPIs:\n" +
"Objectives: Clearly document how feedback data will be utilized, such as for prompt fine-tuning, RAG document updates," +
"model/data drift detection, or more advanced uses like Reinforcement Learning from Human Feedback (RLHF).\nKPI Alignment: Design feedback questions and metrics " +
"to align with the solution’s key performance indicators (KPIs). For example, if accuracy is a KPI, feedback might involve users or SMEs annotating if an answer was correct.",
},
},
{
Id: "AIR-DET-011.2",
Title: "Types of Feedback and Collection Methods",
Prose: "Implementing an effective human feedback loop involves clear collection processes.",
Recommendations: []string{
"Quantitative Feedback:\n" +
"Description: Involves collecting structured responses that can be easily aggregated and measured, such as numerical ratings " +
"(e.g., “Rate this response on a scale of 1-5 for helpfulness”), categorical choices (e.g., “Was this answer: Correct/Incorrect/Partially Correct”), " +
"or binary responses (e.g., thumbs up/down).\nUse Cases: Effective for tracking trends, measuring against KPIs, and quickly identifying areas of high or low performance.",
},
},
},
GuidelineMappings: []Mapping{
{
ReferenceId: "NIST-800-53",
Entries: []MappingEntry{
{
ReferenceId: "CA-7",
Strength: 7,
Remarks: "This control is closely related to CA-7.",
},
{
ReferenceId: "IR-6",
Strength: 5,
Remarks: "This control has some relevance to IR-6.",
},
{
ReferenceId: "PM-26",
Strength: 3,
Remarks: "This control is loosely related to PM-26.",
},
{
ReferenceId: "RA-5",
Strength: 7,
Remarks: "This control is closely related to RA-5.",
},
{
ReferenceId: "SI-2",
Strength: 5,
Remarks: "This control has some relevance to SI-2.",
},
},
},
},
PrincipleMappings: []Mapping{
{
ReferenceId: "AIR-PRIN",
Entries: []MappingEntry{
{
ReferenceId: "TIMELINESS",
Strength: 7,
Remarks: "This principle emphasizes the importance of timely feedback.",
},
},
},
},
SeeAlso: []string{
"AIR-DET-015",
"AIR-DET-004",
"AIR-PREV-005",
},
},
},
},
},
}
t, err := template.New("guidance").Parse(tmpl)
if err != nil {
fmt.Printf("error parsing template: %v\n", err)
}
err = t.Execute(os.Stdout, l1Docs)
if err != nil {
fmt.Printf("error executing template: %v\n", err)
}
Output: # AI Governance Framework (FINOS-AIR) --- **Front Matter:** The following framework has been developed by FINOS (Fintech Open Source Foundation). --- ### Detective (DET) Detection and Continuous Improvement #### Guidelines: ##### Human Feedback Loop for AI Systems (AIR-DET-011) **Objective:** A Human Feedback Loop is a critical detective and continuous improvement mechanism that involves systematically collecting, analyzing, and acting upon feedback provided by human users, subject matter experts (SMEs), or reviewers regarding an AI system’s performance, outputs, or behavior. **See Also:** AIR-DET-015 AIR-DET-004 AIR-PREV-005
type Guideline ¶
type Guideline struct {
Id string `json:"id" yaml:"id"`
Title string `json:"title" yaml:"title"`
Objective string `json:"objective,omitempty" yaml:"objective,omitempty"`
// Maps to fields commonly seen in controls with implementation guidance
Recommendations []string `json:"recommendations,omitempty" yaml:"recommendations,omitempty"`
// For control enhancements (ex. AC-2(1) in 800-53)
// The base-guideline-id is needed to achieve full context for the enhancement
BaseGuidelineID string `json:"base-guideline-id,omitempty" yaml:"base-guideline-id,omitempty"`
Rationale *Rationale `json:"rationale,omitempty" yaml:"rationale,omitempty"`
// Represents individual guideline parts/statements
GuidelineParts []Part `json:"guideline-parts,omitempty" yaml:"guideline-parts,omitempty"`
// Crosswalking this guideline to other guidelines in other documents
GuidelineMappings []Mapping `json:"guideline-mappings,omitempty" yaml:"guideline-mappings,omitempty"`
// A list for associated key principle ids
PrincipleMappings []Mapping `json:"principle-mappings,omitempty" yaml:"principle-mappings,omitempty"`
// This is akin to related controls, but using more explicit terminology
SeeAlso []string `json:"see-also,omitempty" yaml:"see-also,omitempty"`
// Corresponds to the resource ids in metadata to map to external unstructured resources
ExternalReferences []string `json:"external-references,omitempty" yaml:"external-references,omitempty"`
}
type Mapping ¶
type Mapping struct {
ReferenceId string `json:"reference-id" yaml:"reference-id"`
Entries []MappingEntry `json:"entries" yaml:"entries"`
// Adding context about this particular mapping and why it was mapped.
Remarks string `json:"remarks,omitempty" yaml:"remarks,omitempty"`
}
type MappingEntry ¶
type MappingReference ¶
type MappingReference struct {
Id string `json:"id" yaml:"id"`
Title string `json:"title" yaml:"title"`
Version string `json:"version" yaml:"version"`
Description string `json:"description,omitempty" yaml:"description,omitempty"`
Url string `json:"url,omitempty" yaml:"url,omitempty"`
}
Mapping references is the same from Layer2, but intended for Layer 1 to Layer 1 mappings instead of Layer 2 to Layer 1 mappings.
type Metadata ¶
type Metadata struct {
Id string `json:"id" yaml:"id"`
Title string `json:"title" yaml:"title"`
Description string `json:"description" yaml:"description"`
Author string `json:"author" yaml:"author"`
Version string `json:"version,omitempty" yaml:"version,omitempty"`
LastModified string `json:"last-modified,omitempty" yaml:"last-modified,omitempty"`
PublicationDate string `json:"publication-date,omitempty" yaml:"publication-date,omitempty"`
MappingReferences []MappingReference `json:"mapping-references,omitempty" yaml:"mapping-references,omitempty"`
// References to external resources not represented in a structured format.
Resources []ResourceReference `json:"resources,omitempty" yaml:"resources,omitempty"`
DocumentType DocumentType `json:"document-type,omitempty" yaml:"document-type,omitempty"`
Applicabilty *Applicability `json:"applicability,omitempty" yaml:"applicability,omitempty"`
Exemptions []string `json:"exemptions,omitempty" yaml:"exemptions,omitempty"`
}
type Part ¶
type Part struct {
Id string `json:"id" yaml:"id"`
Title string `json:"title,omitempty" yaml:"title,omitempty"`
Prose string `json:"prose" yaml:"prose"`
Recommendations []string `json:"recommendations,omitempty" yaml:"recommendations,omitempty"`
}
Parts include sub-statements of a guideline that can be assessed individually
type Rationale ¶
type Rationale struct {
// Negative results expected from the guideline's lack of implementation
Risks []Risk `json:"risks" yaml:"risks"`
// Positive results expected from the guideline's implementation
Outcomes []Outcome `json:"outcomes" yaml:"outcomes"`
}
Rationale provides contextual information to help with development and understanding of guideline intent.
type ResourceReference ¶
type ResourceReference struct {
Id string `json:"id" yaml:"id"`
Title string `json:"title" yaml:"title"`
Description string `json:"description" yaml:"description"`
Url string `json:"url,omitempty" yaml:"url,omitempty"`
IssuingBody string `json:"issuing-body,omitempty" yaml:"issuing-body,omitempty"`
PublicationDate string `json:"publication-date,omitempty" yaml:"publication-date,omitempty"`
}
ResourceReferences defines a references to an external document (possibly unstructured)
Click to show internal directories.
Click to hide internal directories.