As you don't seem to use the iPhoto library at all, you should use Image Capture instead. It allows you to put your picture directly in a given folder.
You can also create a "transfer module" with automator which can be set to run after an import using Image Capture with imported pictures as input. Thanks to this, you can create an automator process to arrange them in folder as you want.
Image Capture is also scriptable with AppleScript, you might want to take a look at its dictionary if the GUI or Automator don't provide enough flexibility for you.
If you want your pictures both in iPhoto and in your folder, you can configure the automator process to add them in iPhoto once imported in your folder with Image Capture. Lots of workflow are possible, it depends and what you exactly want to achieve.
To use this (or any) script in a program like Apple Mail, you could create a service in Automator.
Launch the Automator program.
When it says Choose a type for your document, select Service and click Choose
In the top dialog, select Service receives no input in Mail.app (or, the name of your program, or any application if that's what you want).
You will insert one action: From the Utilities group, double-click Run AppleScript.
Select the text that says
(* Your script goes here *)
and paste in the script you want to run. In your case, the script you want to paste is
tell application "Mail"
set theSelection to selection
set theMessage to item 1 of theSelection
set theSubject to subject of theMessage
tell application "Address Book"
set theGroup to make new group with properties {name:theSubject}
end tell
set theRecipients to to recipients of item 1 of theMessage
repeat with a from 1 to count theRecipients
set theRecipient to item a of theRecipients
tell application "Address Book"
set theName to name of theRecipient
tell application "Mail" to set theAddress to address of theRecipient
set thePerson to make new person with properties {first name:name of theRecipient}
make new email at end of emails of thePerson with properties {value:theAddress}
add thePerson to theGroup
end tell
end repeat
set theRecipients to cc recipients of item 1 of theMessage
repeat with a from 1 to count theRecipients
set theRecipient to item a of theRecipients
tell application "Address Book"
set theName to name of theRecipient
tell application "Mail" to set theAddress to address of theRecipient
set thePerson to make new person with properties {first name:name of theRecipient}
make new email at end of emails of thePerson with properties {value:theAddress}
add thePerson to theGroup
end tell
end repeat
tell application "Address Book" to save
end tell
Once you have done that, go to the File menu and click Save.
Give the service a name you will remember, like "Add Recipients to Group".
Then when you are in Mail, you can select a message or messages and go to the Mail menu in the menu bar, then the Services menu in the Mail menu, and select the service Add Recipients to Group.
Best Answer
I don't know how well it would work, but you could try running something like this in AppleScript Editor.