Working version of SAM FBAgent