SAN FRANCISCO -- In the corner of a Fairmont Hotel bar, the men and women around her listening intently and making notes, Charlotte Maillard Swig was considering the placement of the pins. "Piins," said Swig, touching her lapel to indicate that she was not describing writing implements; Swig still charms people with her Texas accent even though she has been making Grand Arrangements in San Francisco for so long that nobody puts on a civic spectacle without consulting her, which is why she was addressing a Thursday meeting whose agenda included pins. The pins feature companionably crisscrossed Soviet and American flags, and each guest is supposed to receive one as a memento of tomorrow's lunch.

Tomorrow's lunch guest -- Northern California corporate executives have spent the last week flinging themselves at the Chamber of Commerce for tickets -- is Mikhail Gorbachev. He gets a pin too. He also gets a paperweight and a program with a nice red tassel on it and a view of many red roses and flags and hand-lettered place cards, all of which must be laid out in diplomatically correct fashion between midnight tonight and the morning arrival of the security men.

There they'll be, Charlotte Maillard Swig and the Chamber of Commerce people and their crews of loyal arrangers, setting tables at 3 in the morning with little spokes-of-a-wheel table charts to make certain each person is placed where he or she belongs. "Once they close the rooms to bring the dogs through," said Stanley Gatti, the designer working with Swig on the one-day Gorbachev visit to San Francisco this week, "that's it. We can't get in."

"Dogs," Swig said, widening her eyes in mock alarm.

"Bomb-sniffing dogs," Gatti said. "Nice dogs."

Actually bomb-sniffing dogs do not appear to cause even faint distress for Swig, who is more famous than anybody in California for causing large partylike events to happen such that most people go home afterward feeling swell. Swig holds a formal if unpaid position in San Francisco; her city government title is chief of protocol, which is somewhat more convenient than saying Person Who Knows Absolutely Everybody and Can Organize Anything and Look Chic at the Same Time. She happens to be married to Melvin Swig, who owns the Fairmont Hotel and rather a lot of other big buildings and socially is no slouch himself, but Charlotte Maillard Swig's reputation was firmly established long before she married Swig in 1988.

The city's biggest charity balls, the three-story City Hall bash during the 1984 Democratic Convention, the massive celebration and bridge walk for the 50th anniversary of the Golden Gate Bridge -- all those were Charlotte Maillard Swig's, and when she goes to work on projects of these dimensions she tends to begin talking rapidly about marching bands, or lavish flower displays, or the small boy and girl who might step from the airport chorus to hand Mikhail and Raisa Gorbachev bouquets of flags and flowers to carry on board as they leave San Francisco. "I thought if they could sing, 'I Left My Heart in San Francisco' as they left, that would be kind of cute, wouldn't it?" Swig asked. "And when he comes, I thought they could play, 'California, Here I Come.' "

She thought at first that military bands might greet the Soviet president, but then the military declined to participate, since this is not an official state visit, so a high school band had to be found, and a color guard arranged, and a receiving line of city officials set up to receive the Gorbachevs tonight, and all of this handled with the proper ceremony while bearing in mind that the arrival will be late and the security people will want to whisk their charges in to safety for the night. "There's lots and lots of detail," Maillard said. "And I think the reason people have said things work out here is because we have a lot of good people. I get too much credit for what I do. It's a matter of orchestrating."

So Swig has marched Soviet advance men around the Fairmont, for example (they did look at other hotel space, Swig said, but chose the Fairmont independent of her family connection), to see which room seemed suitable for the lunch. "I took them in the Gold Room, which is very rococo and baroque -- we had our wedding reception in there -- and they said, 'Nope, we have one like that at home,' " she said. She has called her friends to explain that the city has no budget to pay for any of these arrangements and so they should cough up a lot of money, and quickly. "Right now some unlikely friends are going to be sitting there and I'm going to call them up and ask them for $20,000," Swig said cheerfully, "just for setting up the press room."

She sat through the highly secretive tasting of the Fairmont's luncheon menu: "My poor husband -- the menu we're serving is not the usual Chamber of Commerce bill of fare for lunch." Veal and lamb were examined and considered, with the lamb winning out (reportedly the Soviet president is fond of lamb); the final menu, which is meant to showcase California wines and produce, features canapes of Pacific smoked salmon and Dungeness crab, Pacific lobster medallions with Sonoma greens and butterflied salmon, sourdough bread, roast rack of baby lamb with pinot noir sauce, vegetables from the San Joaquin Valley, chocolate tulips with California berries and sabayon sauce, and copious quantities of Napa and Sonoma wines.

And she worried momentarily, Swig said, when the advance team called her over and asked a question in rapid Russian with extremely serious looks on their faces. "Do you promise," the interpreter translated for them, "that the sun will shine?"

Swig promised. "Get that detail," she said. "I thought I'd call on my clergy friends."