clamsproject / clams-python

CLAMS SDK for python
http://sdk.clams.ai/
Apache License 2.0
4 stars 1 forks source link

`#RAW#` key in `view[].metadata.appConfiguration` #209

Closed keighrim closed 2 months ago

keighrim commented 2 months ago

Bug Description

view[].metadata.parameters map is repeated in view[].metadata.appConfiguration.#RAW#. This is implementation detail and should not be exposed in the output file.

Reproduction steps

output from an app that uses clams-python==1.1.6

...
"views": [                                                                                                    
    {
      "id": "v_0",
      "metadata": {
        "timestamp": "2024-04-09T17:42:37.636944",
        "app": "http://apps.clams.ai/swt-detection/unresolvable",
        "contains": {
          "http://mmif.clams.ai/vocabulary/TimePoint/v4": {
            "document": "d1", 
            "timeUnit": "milliseconds",
            "labelset": [ "B", "S", "S:H", "S:C", "S:D", "S:B", "S:G", "W", "L", "O", "M", "I", "N", "E", "P", "Y", "K", "G", "T", "F", "C", "R", "NEG" ]
          },
          "http://mmif.clams.ai/vocabulary/TimeFrame/v5": {
            "document": "d1", 
            "timeUnit": "milliseconds",
            "labelset": [ "bars", "slate", "other_opening", "chyron", "credit", "other_text" ]
          },
          "http://mmif.clams.ai/vocabulary/Annotation/v5": {
            "document": "d1"
          }
        },    
        "parameters": {
          "pretty": ""
        },
        "appConfiguration": {
          "startAt": 0,
          "stopAt": 10000000,
          "sampleRate": 1000, 
          "minFrameScore": 0.01, 
          "minTimeframeScore": 0.5,
          "minFrameCount": 2,
          "modelName": "20240409-091401.convnext_lg.kfold_013",
          "useStitcher": true, 
          "pretty": true, 
          "#RAW#": {   # !!!
            "pretty": [
              ""    
            ]
          }
        }
      },
      "annotations": [
...

Expected behavior

No response

Log output

No response

Screenshots

No response

Additional context

No response