alps-io / spec

ALPS Specification documents.
59 stars 13 forks source link

Needs schema files #83

Closed koriym closed 5 years ago

koriym commented 5 years ago

It would be great if we have schema files (XSD and JSONSchema). Not only the validator can check the validity but also It helps to complete input in the modern text editor.

koriym commented 5 years ago

@mamund I'm working to create JSONSchema for ALPS.

One question.

I found "type" : "descriptor" in the sample list on last in http://alps.io/spec/drafts/draft-01.html#prop-descriptor .

{ 
  "alps" : {
    "version" : "1.0",
    "doc" : {
      "href" : "http://example.org/samples/full/doc.html"
    },
    "descriptor" : [
      {
        "id" : "search", 
        "type" : "safe",
        "doc" : {"value" : 
          "A search form with a two inputs"
        },
        "descriptor" : [
          {
            "id" : "value",
            "name" : "search",
            "type" : "descriptor",
            "doc" : { "value" : "input for search" }
          },
          { "href" : "#resultType" }
        ]
      },
      {
        "id" : "resultType",
        "type" : "descriptor",
        "description" : {"value" : "results format"},
        "ext" : [
          {
            "href" : "http://alps.io/ext/range", 
            "value" : "summary,detail"
          }
        ]
      }
    ]  
  }
}            

but type should be either semantic, safe, idempotent or unsafe ? http://alps.io/spec/drafts/draft-01.html#rfc.section.2.2.12

What is the type descriptor?

mamund commented 5 years ago

Hmmmm.

Not sure about this.

Is this summer kind of extension?

Or just a typo?

On Fri, Apr 5, 2019, 23:00 Akihito Koriyama notifications@github.com wrote:

@mamund https://github.com/mamund I'm working to create JSONSchema for ALPS.

One question.

I found "type" : "descriptor" in the sample list on last in http://alps.io/spec/drafts/draft-01.html#prop-descriptor .

{ "alps" : { "version" : "1.0", "doc" : { "href" : "http://example.org/samples/full/doc.html" }, "descriptor" : [ { "id" : "search", "type" : "safe", "doc" : {"value" : "A search form with a two inputs" }, "descriptor" : [ { "id" : "value", "name" : "search", "type" : "descriptor", "doc" : { "value" : "input for search" } }, { "href" : "#resultType" } ] }, { "id" : "resultType", "type" : "descriptor", "description" : {"value" : "results format"}, "ext" : [ { "href" : "http://alps.io/ext/range", "value" : "summary,detail" } ] } ] } }

but type should be either semantic, safe, idempotent or unsafe ? http://alps.io/spec/drafts/draft-01.html#rfc.section.2.2.12

What is the type descriptor?

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/alps-io/spec/issues/83#issuecomment-480468537, or mute the thread https://github.com/notifications/unsubscribe-auth/AACVyPB0VduSEJiv4aAwXLbNxczeDLtDks5veA27gaJpZM4cf7yk .

koriym commented 5 years ago

Seems typo for me ...

koriym commented 5 years ago

Found PR (the year 2015) for this 😅 https://github.com/alps-io/spec/pull/76

koriym commented 5 years ago

@mamund You are welcome. Feel good that I could contribute your work at last. :)

mamund commented 5 years ago

happy we are working on this together, too.