SYNTOLOGY HomeExplorerAtlasCodeMethodologyAboutDevelopersFeedPricing
Paper · 2410.21411 · NeurIPS · 2024

SocialGPT: Prompting LLMs for Social Relation Reasoning via Greedy Segment Optimization

Chuang Gan, Hanspeter Pfister, Donglai Wei, Jiawei Zhou, Wanhua Li, Zibin Meng

arXiv · PDF · Open in the Atlas

Code that ran

We lifted 3 functions out of this paper's own repositories and ran 1 of them in a sandbox. "Ran" means the function executed on a synthesized input and returned a value. It is not a reproduction of the paper's results.

RepositoryRoleRan
mengzibin/socialgpt canonical 1 of 1
Mengzibin/SocialGPT canonical 0 of 2
FunctionStatusWhere it lives
ProgressiveMultiPromptStory Ran mengzibin/socialgpt/GSPO-PIPA/llm_prompt/base/prompt_manager.py
pointer only (licence: NONE) · get_code("90d108caba3c8524")
bbox_xywh_to_xyxy Not yet run Mengzibin/SocialGPT/social-story-main-PIPA/models/region_semantic.py
pointer only (licence: NONE) · get_code("a404f3d6373002f0")
pil_image_to_base64 Not yet run Mengzibin/SocialGPT/social-story-main-PIPA/models/image_text_transformation.py
pointer only (licence: NONE) · get_code("a134d4aa43dba9df")

Repositories linked to this paper

Some links come from the archived Papers with Code dataset (CC BY-SA 4.0): attribution and licence.

Abstract

Social relation reasoning aims to identify relation categories such as friends, spouses, and colleagues from images. While current methods adopt the paradigm of training a dedicated network end-to-end using labeled image data, they are limited in terms of generalizability and interpretability. To address these issues, we first present a simple yet well-crafted framework named SocialGPT, which combines the perception capability of Vision Foundation Models (VFMs) and the reasoning capability of Large Language Models (LLMs) within a modular framework, providing a strong baseline for social relation recognition. Specifically, we instruct VFMs to translate image content into a textual social story, and then utilize LLMs for text-based reasoning. SocialGPT introduces systematic design principles to adapt VFMs and LLMs separately and bridge their gaps. Without additional model training, it achieves competitive zero-shot results on two databases while offering interpretable answers, as LLMs can generate language-based explanations for the decisions. The manual prompt design process for LLMs at the reasoning phase is tedious and an automated prompt optimization method is desired. As we essentially convert a visual classification task into a generative task of LLMs, automatic prompt optimization encounters a unique long prompt optimization issue. To address this issue, we further propose the Greedy Segment Prompt Optimization (GSPO), which performs a greedy search by utilizing gradient information at the segment level. Experimental results show that GSPO significantly improves performance, and our method also generalizes to different image styles. The code is available at https://github.com/Mengzibin/SocialGPT.

For agents

The same record, over MCP at https://syntology.ai/mcp:

get_harvested_code_for_paper("2410.21411")
get_code_for_paper("2410.21411")
have("2410.21411")

Connect an agent — have() is free.