LPX commited on
Commit
2f1900e
Β·
1 Parent(s): f69af75

feat: add API names to prediction functions and update README title for clarity

Browse files
Files changed (2) hide show
  1. README.md +1 -1
  2. app_mcp.py +9 -5
README.md CHANGED
@@ -1,5 +1,5 @@
1
  ---
2
- title: Deepfake Detection & Forensics Tools
3
  description: MCP Server for Deepfake Detection & Digital Forensics Tools
4
  emoji: πŸš‘
5
  colorFrom: yellow
 
1
  ---
2
+ title: MCP Toolkit - Deepfake Detection & Forensics
3
  description: MCP Server for Deepfake Detection & Digital Forensics Tools
4
  emoji: πŸš‘
5
  colorFrom: yellow
app_mcp.py CHANGED
@@ -532,7 +532,8 @@ with gr.Blocks(css="#post-gallery { overflow: hidden !important;} .grid-wrap{ ov
532
  predict_button.click(
533
  fn=predict_image_with_json,
534
  inputs=inputs,
535
- outputs=outputs
 
536
  )
537
  augment_button.click( # Connect Augment button to the function
538
  fn=predict_image_with_json,
@@ -544,7 +545,8 @@ with gr.Blocks(css="#post-gallery { overflow: hidden !important;} .grid-wrap{ ov
544
  noise_slider,
545
  sharpen_slider
546
  ],
547
- outputs=outputs
 
548
  )
549
  with gr.Tab("πŸ™ˆ Project Introduction"):
550
  gr.Markdown(QUICK_INTRO)
@@ -561,7 +563,8 @@ with gr.Blocks(css="#post-gallery { overflow: hidden !important;} .grid-wrap{ ov
561
  inputs=[gr.Image(type="pil"), gr.Slider(1, 32, value=8, step=1, label="Block Size")],
562
  outputs=gr.Image(type="pil"),
563
  title="Wavelet-Based Noise Analysis",
564
- description="Analyzes image noise patterns using wavelet decomposition. This tool helps detect compression artifacts and artificial noise patterns that may indicate image manipulation. Higher noise levels in specific regions can reveal areas of potential tampering."
 
565
  )
566
 
567
 
@@ -576,7 +579,8 @@ with gr.Blocks(css="#post-gallery { overflow: hidden !important;} .grid-wrap{ ov
576
  ],
577
  outputs=gr.Image(type="pil"),
578
  title="Bit Plane Analysis",
579
- description="Extracts and visualizes individual bit planes from different color channels. This forensic tool helps identify hidden patterns and artifacts in image data that may indicate manipulation. Different bit planes can reveal inconsistencies in image processing or editing."
 
580
  )
581
  # with gr.Tab("EXIF Full Dump"):
582
  # gr.Interface(
@@ -598,4 +602,4 @@ if __name__ == "__main__":
598
  private=False, # Keep your dataset private
599
  token=os.getenv("HF_TOKEN") # Uncomment and set if token is not saved globally
600
  ) as scheduler:
601
- demo.launch(share=True, mcp_server=True)
 
532
  predict_button.click(
533
  fn=predict_image_with_json,
534
  inputs=inputs,
535
+ outputs=outputs,
536
+ api_name="Infer: Full Predict"
537
  )
538
  augment_button.click( # Connect Augment button to the function
539
  fn=predict_image_with_json,
 
545
  noise_slider,
546
  sharpen_slider
547
  ],
548
+ outputs=outputs,
549
+ api_name="Infer: Augment then Predict"
550
  )
551
  with gr.Tab("πŸ™ˆ Project Introduction"):
552
  gr.Markdown(QUICK_INTRO)
 
563
  inputs=[gr.Image(type="pil"), gr.Slider(1, 32, value=8, step=1, label="Block Size")],
564
  outputs=gr.Image(type="pil"),
565
  title="Wavelet-Based Noise Analysis",
566
+ description="Analyzes image noise patterns using wavelet decomposition. This tool helps detect compression artifacts and artificial noise patterns that may indicate image manipulation. Higher noise levels in specific regions can reveal areas of potential tampering.",
567
+ api_name="Tool: Wavelet Noise Estimation"
568
  )
569
 
570
 
 
579
  ],
580
  outputs=gr.Image(type="pil"),
581
  title="Bit Plane Analysis",
582
+ description="Extracts and visualizes individual bit planes from different color channels. This forensic tool helps identify hidden patterns and artifacts in image data that may indicate manipulation. Different bit planes can reveal inconsistencies in image processing or editing.",
583
+ api_name="Tool: Bitplane Extractor"
584
  )
585
  # with gr.Tab("EXIF Full Dump"):
586
  # gr.Interface(
 
602
  private=False, # Keep your dataset private
603
  token=os.getenv("HF_TOKEN") # Uncomment and set if token is not saved globally
604
  ) as scheduler:
605
+ demo.launch(share=True)