{
  "schemaVersion": "1.0",
  "item": {
    "slug": "fosmvvm-fields-generator",
    "name": "FOSMVVM Fields Generator",
    "source": "tencent",
    "type": "skill",
    "category": "通讯协作",
    "sourceUrl": "https://clawhub.ai/foscomputerservices/fosmvvm-fields-generator",
    "canonicalUrl": "https://clawhub.ai/foscomputerservices/fosmvvm-fields-generator",
    "targetPlatform": "OpenClaw"
  },
  "install": {
    "downloadMode": "redirect",
    "downloadUrl": "/downloads/fosmvvm-fields-generator",
    "sourceDownloadUrl": "https://wry-manatee-359.convex.site/api/v1/download?slug=fosmvvm-fields-generator",
    "sourcePlatform": "tencent",
    "targetPlatform": "OpenClaw",
    "installMethod": "Manual import",
    "extraction": "Extract archive",
    "prerequisites": [
      "OpenClaw"
    ],
    "packageFormat": "ZIP package",
    "includedAssets": [
      "SKILL.md",
      "reference.md"
    ],
    "primaryDoc": "SKILL.md",
    "quickSetup": [
      "Download the package from Yavira.",
      "Extract the archive and review SKILL.md first.",
      "Import or place the package into your OpenClaw setup."
    ],
    "agentAssist": {
      "summary": "Hand the extracted package to your coding agent with a concrete install brief instead of figuring it out manually.",
      "steps": [
        "Download the package from Yavira.",
        "Extract it into a folder your agent can access.",
        "Paste one of the prompts below and point your agent at the extracted folder."
      ],
      "prompts": [
        {
          "label": "New install",
          "body": "I downloaded a skill package from Yavira. Read SKILL.md from the extracted folder and install it by following the included instructions. Tell me what you changed and call out any manual steps you could not complete."
        },
        {
          "label": "Upgrade existing",
          "body": "I downloaded an updated skill package from Yavira. Read SKILL.md from the extracted folder, compare it with my current installation, and upgrade it while preserving any custom configuration unless the package docs explicitly say otherwise. Summarize what changed and any follow-up checks I should run."
        }
      ]
    },
    "sourceHealth": {
      "source": "tencent",
      "status": "healthy",
      "reason": "direct_download_ok",
      "recommendedAction": "download",
      "checkedAt": "2026-04-23T16:43:11.935Z",
      "expiresAt": "2026-04-30T16:43:11.935Z",
      "httpStatus": 200,
      "finalUrl": "https://wry-manatee-359.convex.site/api/v1/download?slug=4claw-imageboard",
      "contentType": "application/zip",
      "probeMethod": "head",
      "details": {
        "probeUrl": "https://wry-manatee-359.convex.site/api/v1/download?slug=4claw-imageboard",
        "contentDisposition": "attachment; filename=\"4claw-imageboard-1.0.1.zip\"",
        "redirectLocation": null,
        "bodySnippet": null
      },
      "scope": "source",
      "summary": "Source download looks usable.",
      "detail": "Yavira can redirect you to the upstream package for this source.",
      "primaryActionLabel": "Download for OpenClaw",
      "primaryActionHref": "/downloads/fosmvvm-fields-generator"
    },
    "validation": {
      "installChecklist": [
        "Use the Yavira download entry.",
        "Review SKILL.md after the package is downloaded.",
        "Confirm the extracted package contains the expected setup assets."
      ],
      "postInstallChecks": [
        "Confirm the extracted package includes the expected docs or setup files.",
        "Validate the skill or prompts are available in your target agent workspace.",
        "Capture any manual follow-up steps the agent could not complete."
      ]
    },
    "downloadPageUrl": "https://openagent3.xyz/downloads/fosmvvm-fields-generator",
    "agentPageUrl": "https://openagent3.xyz/skills/fosmvvm-fields-generator/agent",
    "manifestUrl": "https://openagent3.xyz/skills/fosmvvm-fields-generator/agent.json",
    "briefUrl": "https://openagent3.xyz/skills/fosmvvm-fields-generator/agent.md"
  },
  "agentAssist": {
    "summary": "Hand the extracted package to your coding agent with a concrete install brief instead of figuring it out manually.",
    "steps": [
      "Download the package from Yavira.",
      "Extract it into a folder your agent can access.",
      "Paste one of the prompts below and point your agent at the extracted folder."
    ],
    "prompts": [
      {
        "label": "New install",
        "body": "I downloaded a skill package from Yavira. Read SKILL.md from the extracted folder and install it by following the included instructions. Tell me what you changed and call out any manual steps you could not complete."
      },
      {
        "label": "Upgrade existing",
        "body": "I downloaded an updated skill package from Yavira. Read SKILL.md from the extracted folder, compare it with my current installation, and upgrade it while preserving any custom configuration unless the package docs explicitly say otherwise. Summarize what changed and any follow-up checks I should run."
      }
    ]
  },
  "documentation": {
    "source": "clawhub",
    "primaryDoc": "SKILL.md",
    "sections": [
      {
        "title": "FOSMVVM Fields Generator",
        "body": "Generate Form Specifications following FOSMVVM patterns."
      },
      {
        "title": "Conceptual Foundation",
        "body": "For full architecture context, see FOSMVVMArchitecture.md | OpenClaw reference\n\nA Form Specification (implemented as a {Name}Fields protocol) is the single source of truth for user input. It answers:\n\nWhat data can the user provide? (properties)\nHow should it be presented? (FormField with type, keyboard, autofill semantics)\nWhat constraints apply? (validation rules)\nWhat messages should be shown? (localized titles, placeholders, errors)"
      },
      {
        "title": "Why This Matters",
        "body": "The Form Specification is defined once, used everywhere:\n\n// Same protocol adopted by different consumers:\nstruct CreateIdeaRequestBody: ServerRequestBody, IdeaFields { ... }  // HTTP transmission\n@ViewModel struct IdeaFormViewModel: IdeaFields { ... }              // Form rendering\nfinal class Idea: Model, IdeaFields { ... }                          // Persistence validation\n\nThis ensures:\n\nConsistent validation - Same rules on client and server\nShared localization - One YAML file, used everywhere\nSingle source of truth - Change once, applies everywhere"
      },
      {
        "title": "Connection to FOSMVVM",
        "body": "Form Specifications integrate with:\n\nLocalization System - FormField titles/placeholders and validation messages use LocalizableString\nValidation System - Implements ValidatableModel protocol\nRequest System - RequestBody types adopt Fields for validated transmission\nViewModel System - ViewModels adopt Fields for form rendering"
      },
      {
        "title": "When to Use This Skill",
        "body": "Defining a new form (create, edit, filter, search)\nAdding validation to a request body\nAny type that needs to conform to ValidatableModel\nWhen fosmvvm-fluent-datamodel-generator needs form fields for a DataModel"
      },
      {
        "title": "What This Skill Generates",
        "body": "A complete Form Specification consists of 3 files:\n\nFilePurpose{Name}Fields.swiftProtocol + FormField definitions + validation methods{Name}FieldsMessages.swift@FieldValidationModel struct with @LocalizedString properties{Name}FieldsMessages.ymlYAML localization (titles, placeholders, error messages)"
      },
      {
        "title": "Project Structure Configuration",
        "body": "Replace placeholders with your project's actual paths:\n\nPlaceholderDescriptionExample{ViewModelsTarget}Shared ViewModels SPM targetViewModels, SharedViewModels{ResourcesPath}Localization resources pathSources/Resources\n\nExpected Structure:\n\nSources/\n  {ViewModelsTarget}/\n    FieldModels/\n      {Name}Fields.swift\n      {Name}FieldsMessages.swift\n  {ResourcesPath}/\n    FieldModels/\n      {Name}FieldsMessages.yml"
      },
      {
        "title": "How to Use This Skill",
        "body": "Invocation:\n/fosmvvm-fields-generator\n\nPrerequisites:\n\nForm purpose understood from conversation context\nField requirements discussed (names, types, constraints)\nEntity relationship identified (what is this form creating/editing)\n\nWorkflow integration:\nThis skill is used when defining form validation and user input contracts. The skill references conversation context automatically—no file paths or Q&A needed. Often precedes fosmvvm-fluent-datamodel-generator for form-backed models."
      },
      {
        "title": "Pattern Implementation",
        "body": "This skill references conversation context to determine Fields protocol structure:"
      },
      {
        "title": "Form Analysis",
        "body": "From conversation context, the skill identifies:\n\nForm purpose (create, edit, filter, login, settings)\nEntity relation (User, Idea, Document - what's being created/edited)\nProtocol naming (CreateIdeaFields, UpdateProfile, LoginCredentials)"
      },
      {
        "title": "Field Design",
        "body": "For each field from requirements:\n\nProperty specification (name, type, optional vs required)\nPresentation type (FormFieldType: text, textArea, select, checkbox)\nInput semantics (FormInputType: email, password, tel, date)\nConstraints (required, length range, value range, date range)\nLocalization (title, placeholder, validation error messages)"
      },
      {
        "title": "File Generation Order",
        "body": "Fields protocol with FormField definitions and validation\nFieldsMessages struct with @LocalizedString properties\nFieldsMessages YAML with localized strings"
      },
      {
        "title": "Context Sources",
        "body": "Skill references information from:\n\nPrior conversation: Form requirements, field specifications discussed\nSpecification files: If Claude has read form specs into context\nExisting patterns: From codebase analysis of similar Fields protocols"
      },
      {
        "title": "Protocol Structure",
        "body": "public protocol {Name}Fields: ValidatableModel, Codable, Sendable {\n    var fieldName: FieldType { get set }\n    var {name}ValidationMessages: {Name}FieldsMessages { get }\n}"
      },
      {
        "title": "FormField Definition",
        "body": "static var contentField: FormField<String?> { .init(\n    fieldId: .init(id: \"content\"),\n    title: .localized(for: {Name}FieldsMessages.self, propertyName: \"content\", messageKey: \"title\"),\n    placeholder: .localized(for: {Name}FieldsMessages.self, propertyName: \"content\", messageKey: \"placeholder\"),\n    type: .textArea(inputType: .text),\n    options: [\n        .required(value: true)\n    ] + FormInputOption.rangeLength(contentRange)\n) }"
      },
      {
        "title": "FormField Types Reference",
        "body": "FormFieldTypeUse Case.text(inputType:)Single-line input.textArea(inputType:)Multi-line input.checkboxBoolean toggle.selectDropdown selection.colorPickerColor selection"
      },
      {
        "title": "FormInputType Reference (common ones)",
        "body": "FormInputTypeKeyboard/Autofill.textDefault keyboard.emailAddressEmail keyboard, email autofill.passwordSecure entry.telPhone keyboard.urlURL keyboard.date, .datetimeLocalDate picker.givenName, .familyNameName autofill"
      },
      {
        "title": "Validation Method Pattern",
        "body": "internal func validateContent(_ fields: [FormFieldBase]?) -> [ValidationResult]? {\n    guard fields == nil || (fields?.contains(Self.contentField) == true) else {\n        return nil\n    }\n\n    var result = [ValidationResult]()\n\n    if content.isEmpty {\n        result.append(.init(\n            status: .error,\n            field: Self.contentField,\n            message: {name}ValidationMessages.contentRequiredMessage\n        ))\n    } else if !Self.contentRange.contains(NSString(string: content).length) {\n        result.append(.init(\n            status: .error,\n            field: Self.contentField,\n            message: {name}ValidationMessages.contentOutOfRangeMessage\n        ))\n    }\n\n    return result.isEmpty ? nil : result\n}"
      },
      {
        "title": "Messages Struct Pattern",
        "body": "@FieldValidationModel public struct {Name}FieldsMessages {\n    @LocalizedString(\"content\", messageGroup: \"validationMessages\", messageKey: \"required\")\n    public var contentRequiredMessage\n\n    @LocalizedString(\"content\", messageGroup: \"validationMessages\", messageKey: \"outOfRange\")\n    public var contentOutOfRangeMessage\n}"
      },
      {
        "title": "YAML Structure",
        "body": "en:\n  {Name}FieldsMessages:\n    content:\n      title: \"Content\"\n      placeholder: \"Enter your content...\"\n      validationMessages:\n        required: \"Content is required\"\n        outOfRange: \"Content must be between 1 and 10,000 characters\""
      },
      {
        "title": "Naming Conventions",
        "body": "ConceptConventionExampleProtocol{Name}FieldsIdeaFields, CreateIdeaFieldsMessages struct{Name}FieldsMessagesIdeaFieldsMessagesMessages property{name}ValidationMessagesideaValidationMessagesField definition{fieldName}FieldcontentFieldRange constant{fieldName}RangecontentRangeValidate methodvalidate{FieldName}validateContentRequired message{fieldName}RequiredMessagecontentRequiredMessageOutOfRange message{fieldName}OutOfRangeMessagecontentOutOfRangeMessage"
      },
      {
        "title": "See Also",
        "body": "FOSMVVMArchitecture.md - Full FOSMVVM architecture reference\nfosmvvm-viewmodel-generator - For ViewModels that adopt Fields\nfosmvvm-fluent-datamodel-generator - For Fluent DataModels that implement Fields\nreference.md - Complete file templates"
      },
      {
        "title": "Version History",
        "body": "VersionDateChanges1.02024-12-24Initial skill2.02024-12-26Rewritten with conceptual foundation; generalized from Kairos-specific2.12026-01-24Update to context-aware approach (remove file-parsing/Q&A). Skill references conversation context instead of asking questions or accepting file paths."
      }
    ],
    "body": "FOSMVVM Fields Generator\n\nGenerate Form Specifications following FOSMVVM patterns.\n\nConceptual Foundation\n\nFor full architecture context, see FOSMVVMArchitecture.md | OpenClaw reference\n\nA Form Specification (implemented as a {Name}Fields protocol) is the single source of truth for user input. It answers:\n\nWhat data can the user provide? (properties)\nHow should it be presented? (FormField with type, keyboard, autofill semantics)\nWhat constraints apply? (validation rules)\nWhat messages should be shown? (localized titles, placeholders, errors)\nWhy This Matters\n\nThe Form Specification is defined once, used everywhere:\n\n// Same protocol adopted by different consumers:\nstruct CreateIdeaRequestBody: ServerRequestBody, IdeaFields { ... }  // HTTP transmission\n@ViewModel struct IdeaFormViewModel: IdeaFields { ... }              // Form rendering\nfinal class Idea: Model, IdeaFields { ... }                          // Persistence validation\n\n\nThis ensures:\n\nConsistent validation - Same rules on client and server\nShared localization - One YAML file, used everywhere\nSingle source of truth - Change once, applies everywhere\nConnection to FOSMVVM\n\nForm Specifications integrate with:\n\nLocalization System - FormField titles/placeholders and validation messages use LocalizableString\nValidation System - Implements ValidatableModel protocol\nRequest System - RequestBody types adopt Fields for validated transmission\nViewModel System - ViewModels adopt Fields for form rendering\nWhen to Use This Skill\nDefining a new form (create, edit, filter, search)\nAdding validation to a request body\nAny type that needs to conform to ValidatableModel\nWhen fosmvvm-fluent-datamodel-generator needs form fields for a DataModel\nWhat This Skill Generates\n\nA complete Form Specification consists of 3 files:\n\nFile\tPurpose\n{Name}Fields.swift\tProtocol + FormField definitions + validation methods\n{Name}FieldsMessages.swift\t@FieldValidationModel struct with @LocalizedString properties\n{Name}FieldsMessages.yml\tYAML localization (titles, placeholders, error messages)\nProject Structure Configuration\n\nReplace placeholders with your project's actual paths:\n\nPlaceholder\tDescription\tExample\n{ViewModelsTarget}\tShared ViewModels SPM target\tViewModels, SharedViewModels\n{ResourcesPath}\tLocalization resources path\tSources/Resources\n\nExpected Structure:\n\nSources/\n  {ViewModelsTarget}/\n    FieldModels/\n      {Name}Fields.swift\n      {Name}FieldsMessages.swift\n  {ResourcesPath}/\n    FieldModels/\n      {Name}FieldsMessages.yml\n\nHow to Use This Skill\n\nInvocation: /fosmvvm-fields-generator\n\nPrerequisites:\n\nForm purpose understood from conversation context\nField requirements discussed (names, types, constraints)\nEntity relationship identified (what is this form creating/editing)\n\nWorkflow integration: This skill is used when defining form validation and user input contracts. The skill references conversation context automatically—no file paths or Q&A needed. Often precedes fosmvvm-fluent-datamodel-generator for form-backed models.\n\nPattern Implementation\n\nThis skill references conversation context to determine Fields protocol structure:\n\nForm Analysis\n\nFrom conversation context, the skill identifies:\n\nForm purpose (create, edit, filter, login, settings)\nEntity relation (User, Idea, Document - what's being created/edited)\nProtocol naming (CreateIdeaFields, UpdateProfile, LoginCredentials)\nField Design\n\nFor each field from requirements:\n\nProperty specification (name, type, optional vs required)\nPresentation type (FormFieldType: text, textArea, select, checkbox)\nInput semantics (FormInputType: email, password, tel, date)\nConstraints (required, length range, value range, date range)\nLocalization (title, placeholder, validation error messages)\nFile Generation Order\nFields protocol with FormField definitions and validation\nFieldsMessages struct with @LocalizedString properties\nFieldsMessages YAML with localized strings\nContext Sources\n\nSkill references information from:\n\nPrior conversation: Form requirements, field specifications discussed\nSpecification files: If Claude has read form specs into context\nExisting patterns: From codebase analysis of similar Fields protocols\nKey Patterns\nProtocol Structure\npublic protocol {Name}Fields: ValidatableModel, Codable, Sendable {\n    var fieldName: FieldType { get set }\n    var {name}ValidationMessages: {Name}FieldsMessages { get }\n}\n\nFormField Definition\nstatic var contentField: FormField<String?> { .init(\n    fieldId: .init(id: \"content\"),\n    title: .localized(for: {Name}FieldsMessages.self, propertyName: \"content\", messageKey: \"title\"),\n    placeholder: .localized(for: {Name}FieldsMessages.self, propertyName: \"content\", messageKey: \"placeholder\"),\n    type: .textArea(inputType: .text),\n    options: [\n        .required(value: true)\n    ] + FormInputOption.rangeLength(contentRange)\n) }\n\nFormField Types Reference\nFormFieldType\tUse Case\n.text(inputType:)\tSingle-line input\n.textArea(inputType:)\tMulti-line input\n.checkbox\tBoolean toggle\n.select\tDropdown selection\n.colorPicker\tColor selection\nFormInputType Reference (common ones)\nFormInputType\tKeyboard/Autofill\n.text\tDefault keyboard\n.emailAddress\tEmail keyboard, email autofill\n.password\tSecure entry\n.tel\tPhone keyboard\n.url\tURL keyboard\n.date, .datetimeLocal\tDate picker\n.givenName, .familyName\tName autofill\nValidation Method Pattern\ninternal func validateContent(_ fields: [FormFieldBase]?) -> [ValidationResult]? {\n    guard fields == nil || (fields?.contains(Self.contentField) == true) else {\n        return nil\n    }\n\n    var result = [ValidationResult]()\n\n    if content.isEmpty {\n        result.append(.init(\n            status: .error,\n            field: Self.contentField,\n            message: {name}ValidationMessages.contentRequiredMessage\n        ))\n    } else if !Self.contentRange.contains(NSString(string: content).length) {\n        result.append(.init(\n            status: .error,\n            field: Self.contentField,\n            message: {name}ValidationMessages.contentOutOfRangeMessage\n        ))\n    }\n\n    return result.isEmpty ? nil : result\n}\n\nMessages Struct Pattern\n@FieldValidationModel public struct {Name}FieldsMessages {\n    @LocalizedString(\"content\", messageGroup: \"validationMessages\", messageKey: \"required\")\n    public var contentRequiredMessage\n\n    @LocalizedString(\"content\", messageGroup: \"validationMessages\", messageKey: \"outOfRange\")\n    public var contentOutOfRangeMessage\n}\n\nYAML Structure\nen:\n  {Name}FieldsMessages:\n    content:\n      title: \"Content\"\n      placeholder: \"Enter your content...\"\n      validationMessages:\n        required: \"Content is required\"\n        outOfRange: \"Content must be between 1 and 10,000 characters\"\n\nNaming Conventions\nConcept\tConvention\tExample\nProtocol\t{Name}Fields\tIdeaFields, CreateIdeaFields\nMessages struct\t{Name}FieldsMessages\tIdeaFieldsMessages\nMessages property\t{name}ValidationMessages\tideaValidationMessages\nField definition\t{fieldName}Field\tcontentField\nRange constant\t{fieldName}Range\tcontentRange\nValidate method\tvalidate{FieldName}\tvalidateContent\nRequired message\t{fieldName}RequiredMessage\tcontentRequiredMessage\nOutOfRange message\t{fieldName}OutOfRangeMessage\tcontentOutOfRangeMessage\nSee Also\nFOSMVVMArchitecture.md - Full FOSMVVM architecture reference\nfosmvvm-viewmodel-generator - For ViewModels that adopt Fields\nfosmvvm-fluent-datamodel-generator - For Fluent DataModels that implement Fields\nreference.md - Complete file templates\nVersion History\nVersion\tDate\tChanges\n1.0\t2024-12-24\tInitial skill\n2.0\t2024-12-26\tRewritten with conceptual foundation; generalized from Kairos-specific\n2.1\t2026-01-24\tUpdate to context-aware approach (remove file-parsing/Q&A). Skill references conversation context instead of asking questions or accepting file paths."
  },
  "trust": {
    "sourceLabel": "tencent",
    "provenanceUrl": "https://clawhub.ai/foscomputerservices/fosmvvm-fields-generator",
    "publisherUrl": "https://clawhub.ai/foscomputerservices/fosmvvm-fields-generator",
    "owner": "foscomputerservices",
    "version": "2.0.6",
    "license": null,
    "verificationStatus": "Indexed source record"
  },
  "links": {
    "detailUrl": "https://openagent3.xyz/skills/fosmvvm-fields-generator",
    "downloadUrl": "https://openagent3.xyz/downloads/fosmvvm-fields-generator",
    "agentUrl": "https://openagent3.xyz/skills/fosmvvm-fields-generator/agent",
    "manifestUrl": "https://openagent3.xyz/skills/fosmvvm-fields-generator/agent.json",
    "briefUrl": "https://openagent3.xyz/skills/fosmvvm-fields-generator/agent.md"
  }
}